Question

suppose that a full 4-ary tree has 100 leaves. howmany internal vertices does it have? please...

suppose that a full 4-ary tree has 100 leaves. howmany internal vertices does it have?

please explain in detail.

i dont want to know about no. of vertices i just need to find internal vertices . can you also explain how is 4 ary tree look alike.?

thanks,

0 0
Add a comment Improve this question Transcribed image text
Answer #1

for n-ary tree we have
if it is 1-ary tree and i is the internal node then no. of leaves is 1.
if it is 2-ary tree and i is the internal node then no. of leaves is i+1.
if it is 3-ary tree and i is the internal node then no. of leaves is 2i+ 1.
if it is 4-ary tree and i is the internal node then no. of leaves is 3i+ 1.
if n-ary tree and i is the internal node then no. of leaves are (n-1)i + 1
so L=(n-1)i+1
we have
n=4
L=100 we have to calculate i
100=(4-1)i+1
99=3i
i=33 so total no. of internal vertices will be 33.

a 4 ary tree will look like this

A+ A- A+ B+A B-

Add a comment
Know the answer?
Add Answer to:
suppose that a full 4-ary tree has 100 leaves. howmany internal vertices does it have? please...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT