The Gateway to Computer Science Excellence
First time here? Checkout the FAQ!
x
0 votes
1.3k views

A 5-ary tree in which every internal node has exactly 5 children. The number of left nodes in such a tree with 8 internal nodes will be:

  1. 30
  2. 33
  3. 45
  4. 125
asked in Others by Boss (10.7k points)
retagged by | 1.3k views
0
33

2 Answers

0 votes

Option B

In a complete n-ary tree, $L = (n-1) * I + 1$   where L = No. of leaves, I = No. of Internel nodes

Here n = 5, I = 8

Therefore,  L = (5-1) * 8 + 1 = 4 * 8 + 1 = 33

 

answered by (359 points)
0
question asked number of left node

not number of leaves
0

The question was maybe wrongly printed. 
Since Official  Answer key is 9 (i.e. ALL Correct)
Not sure though!

0 votes
The question should ask about total no. Of leaf nodes which is 33

No. Of leaf nodes=(m-1)*I+1

                              =(5-1)*8+1

                             =33
answered by (393 points)

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true
49,541 questions
54,080 answers
187,200 comments
70,990 users