Question DSA-TREE-0004
EasyWhat is the maximum number of nodes in a binary tree of height h (with a single root node having height 0)?
- A.
h²
- B.
2^(h+1) − 1
- C.
Show answer and explanation
Answer: B
Each level doubles: 1 + 2 + 4 + … + 2^h = 2^(h+1) − 1.