⌨️ Coding Patterns (DSA) path
Trees interview questions and study guide
5 lessons from beginner to advanced. Each lesson explains the concept, shows a worked example and lists the follow-up questions interviewers ask next.
Start with lesson 1 →Intermediate 5 lessons
- Return the level-order traversal of a binary tree, and its right side view.
- Find the lowest common ancestor of two nodes in a binary tree (and in a BST).
- Binary tree traversals (inorder, preorder, postorder). Compare recursion, an explicit stack and Morris traversal.
- Validate a binary search tree. Compare inorder list, recursive bounds and iterative inorder.
- Diameter of a binary tree. Compare recomputing heights and a single postorder pass.