Pattern Recognition Drill
Easy Trees
The Problem
Search for a value in a BST. Return the node or None.
What approach would you use?
Think about it before scrolling down.
Compare with root, recurse left or right. O(h) time — O(log n) for balanced, O(n) for skewed.
Common Trap
Iterative version is also fine and avoids stack overhead: while node: go left or right.