GATE | GATE-CS-2007 | Question 43

A complete n-ary tree is a tree in which each node has n children or no children. Let I be the number of internal nodes and L be the number of leaves in a complete n-ary tree. If L = 41, and I = 10, what is the value of n?
(A) 3
(B) 4
(C) 5
(D) 6


Answer: (C)

Explanation: See question 3 of https://www.geeksforgeeks.org/data-structures-and-algorithms-set-11/

Quiz of this Question



My Personal Notes arrow_drop_up
Article Tags :

2


Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.