📜  门| GATE-CS-2015(Set 1)|第65章

📅  最后修改于: 2021-06-28 17:19:26             🧑  作者: Mango

一棵树的高度是其中最长的根到叶路径的长度。高度为5的二叉树中的最大和最小节点数为
(A) 63和6
(B) 64和5
(C) 32和6
(D) 31和5答案: (A)
解释:

Number of nodes is maximum for a perfect binary tree.
A perfect binary tree of height h has 2h+1 - 1 nodes

Number of nodes is minimum for a skewed binary tree.
A perfect binary tree of height h has h+1 nodes.

这个问题的测验