Given a binary tree, find its maximum depth.
The maximum depth is thenumberof nodes along the longest path fromthe root node down tothe farthest leaf node.
Note: A leaf is a node with no children.
Example:
Given binary tree [3,9,20,null,null,15,7],
3
/ \
920
/ \
157return its depth = 3.
提交反馈:
39 / 39 test cases passed.
Status: Accepted
Runtime:0 ms
Submitted:0 minutes ago
You are here!
Your runtime beats 100.00 % of java submissions.