197 views
Consider a binary tree T that has 100 leaf nodes. Then the number of INTERNAL nodes in T that have exactly two children are ______.
in DS | 197 views
0
$99$?
0
if the binary tree is full.

The number of INTERNAL nodes in the binary tree that have exactly two children is calculated as : number of leaf node -1.

you can verify it by some eg.

so for 100 node number of INTERNAL nodes that have exactly two children are 99.

by Boss (15k points)
selected by
0
Is it applicable to any type of binary tree?
+1
yes, it's true for all BT.