Challenge: Tree Depth
Understand how to compute the depth of a binary tree by identifying the longest branch from the root node to any leaf. This lesson guides you through defining tree depth as the number of edges in the longest path, applying it to sample inputs, and encourages hands-on problem solving to reinforce your understanding.
We'll cover the following...
We'll cover the following...
Problem
Given a binary tree, find its depth. The depth of the root is 0. The depth of the tree is the number of edges in ...