The height of a Tree is the height of the root node or the depth of the deepest node.
OR
The height of a tree is the maximum path length from the root to a leaf.
Read - Height and Depth of a Node in Tree
For eg. . A single-node binary tree has height 0, and an empty binary tree has height -1. As another example, the following binary tree has height 3, path [7 -> 12 -> 10 -> 11]
.
|
|