
Binary Search Tree: Traversal & Height - Beau teaches JavaScript
video description
Date: 2022-03-14
Related videos
Comments and reviews: 4
Anthony
Thank you for the video, but I am confused in the min and max functions as you are adding 1 to an object? node.right/node.left would be a an object with value, left, and right properties, so how is it that you can add a number to an object? And how can objects be greater than or less than other objects in the if statements? Sorry, I'm very confused here, I know I'm not understanding something in the code.
reply
Thank you for the video, but I am confused in the min and max functions as you are adding 1 to an object? node.right/node.left would be a an object with value, left, and right properties, so how is it that you can add a number to an object? And how can objects be greater than or less than other objects in the if statements? Sorry, I'm very confused here, I know I'm not understanding something in the code.
reply
Evance
Hmm Your level order traversal was really complicated for me to implement in python. as I am following along in python. I stumble upon an easier pseudo code that uses queue
- Enqueue node
- while queue has element
- deque node
- process node
- enqueue node children
Great set of tutorials thought.
reply
Hmm Your level order traversal was really complicated for me to implement in python. as I am following along in python. I stumble upon an easier pseudo code that uses queue
- Enqueue node
- while queue has element
- deque node
- process node
- enqueue node children
Great set of tutorials thought.
reply
Shadman
Beau should explain what kind of intuition inspired this implementation of findMinHeight() and findMaxHeight() functions. The levelOrder() was just an ingenious implementation. Nice.
reply
Beau should explain what kind of intuition inspired this implementation of findMinHeight() and findMaxHeight() functions. The levelOrder() was just an ingenious implementation. Nice.
reply
Ruth
i'm still confused about the findMinHeight() and findMaxHeight() functions if you could explain each line of code for those functions, that would be great.
reply
i'm still confused about the findMinHeight() and findMaxHeight() functions if you could explain each line of code for those functions, that would be great.
reply
Add a review, comment
Other channel videos















