Binary Trees Checkpoint

Work fresh traces, diagnose invalid implementations, and identify model boundaries.


Get every question correct to pass this checkpoint. You can review feedback, revise your answers, and submit again.

1. A tree has root 8, left child 3, and 3 has right child 6. Counting nodes on the longest path, what is its depth?
2. Root 10 has left child 5, whose right child is 12. Every parent-child local comparison seems valid. Is the whole tree a BST?

Select one answer.

3. After inverting a binary tree twice, what should hold?

Select one answer.

4. In a BST with root 8, children 4 and 12, and nodes 2 and 6 under 4, what is the LCA value of 2 and 6?
5. A recursive maximum-depth routine returns 1 for nil. What happens to a single-node tree if it uses 1+max(child depths)?

Select one answer.

Join Discord