Handshaking Tree

A complete k k -ary tree is a tree in which each node has either k k children or no children. If a certain tree has 65 leaves and 8 internal nodes what is the value of k k ?


The answer is 9.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

3 solutions

Vijay Kumar
Feb 1, 2016

Nice problem...!!! Handshaking is a good title... Title remind me about the "HANDSHAKING LEMMA" , I have learnt before.

If it is 64 then it will be 8, but it is 65 and hence the value of k must be 9.

k = 9 \boxed{k=9}

Hasmik Garyaka
Oct 16, 2017

In a k-ary tree if internal nodes =n, then leaves = n (k-1)n+1. If nodes=8 leaves=8*(k-1)+1=65 and k=9

Zeeshan Ali
Feb 8, 2016

Let the root node have 9 children, two of them are leaf nodes (heaving no children) and the remaining 7 nodes have 9 children each (as leaf nodes of the tree and 7x9=63). therefore we have 65 leaf nodes and the tree is said to be 9-ary :)

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...