MediumHigh Frequency30 min
Binary Search Tree
BST properties, insertion, deletion, validation, and in-order traversal patterns.
BST property: left < root < right. In-order traversal gives sorted output. Lookup/insert/delete are O(log n) balanced, O(n) worst case.
Binary Search Tree
Search the BST
BST Search Walkthrough1 / 4
Try target
7 < 8
7 is smaller than 8, so move to the left subtree.
More in Trees
Binary Tree Fundamentals
Tree terminology, traversal orders (in/pre/post/level), and recursive thinking.
Tree DFS (Depth-First Search)
Recursive and iterative DFS for path sums, diameter, max depth, and subtree problems.
Tree BFS (Level Order)
Use a queue to traverse level by level — solve right-side view, zigzag, and more.