问题
单项选择题
若一棵霍夫曼树有2001个结点,则其叶结点的数目共有 ______。
A.999
B.1000
C.1001
D.100
答案
参考答案:C
解析:
[评析] 若霍夫曼树共有n个结点,而且霍夫曼树中没有度为1的结点,因此有:n=n0+n2
根据二叉树的性质可知n2=n0-1,所以有:
n=n0+(n0•1)=2n0-1
可以得出:n0=(n+1)/2=(2001+1)/2=1001
若一棵霍夫曼树有2001个结点,则其叶结点的数目共有 ______。
A.999
B.1000
C.1001
D.100
参考答案:C
解析:
[评析] 若霍夫曼树共有n个结点,而且霍夫曼树中没有度为1的结点,因此有:n=n0+n2
根据二叉树的性质可知n2=n0-1,所以有:
n=n0+(n0•1)=2n0-1
可以得出:n0=(n+1)/2=(2001+1)/2=1001
请选择方框中所给的信息补全文段的内容。 | |
So I began jogging, playing tennis with friends and (2)______. Gradually I fell in love with sports and my health condition has been improving all the time. Now I'm (3)______ than most students in my class and I'm (4)______. So you see, people can surely change if they have the will and the practice! |