Height of a Heap A heap storing keys has height . Proof by applying the complete binary tree property:
- Let be the height of a heap storing keys.
- Since there are keys at depth and at least one key at depth , we have .
- Hence, or otherwise .
Height of a Heap A heap storing keys has height . Proof by applying the complete binary tree property: