- #1
craig1928
- 1
- 0
2 questions that came up in a past paper.
A binary tree which is both full and complete and has h levels contains a total of 2^(h-1)
leaf nodes. Prove that this is the case for all h > 0.
Show that with h levels the number of internal nodes is 2^(h−1) − 1
proof by induction apparently
anyone can help? I don't really need to understand it if it came up in an exam just to know it off by heart.
Sorry if I've posted in the wrong section.
thanks.
A binary tree which is both full and complete and has h levels contains a total of 2^(h-1)
leaf nodes. Prove that this is the case for all h > 0.
Show that with h levels the number of internal nodes is 2^(h−1) − 1
proof by induction apparently
anyone can help? I don't really need to understand it if it came up in an exam just to know it off by heart.
Sorry if I've posted in the wrong section.
thanks.