Contents

In a full binary tree if number of internal nodes is I, then number of leaves L are?

a) L = 2*I                             
b) L = I + 1
c) L = I – 1                           
d) L = 2*I – 1

b

Explanation: Number of Leaf nodes in full binary tree is equal to 1 + Number of Internal Nodes i.e L = I + 1


In a full binary tree if number of internal nodes is I, then number of nodes N are?
a) N = 2*I                             
b) N = I + 1
c) N = I – 1                           
d) N = 2*I + 1

d

Explanation: Relation between number of internal nodes(I) and nodes(N) is
N = 2*I+1.


In a full binary tree if there are L leaves, then total number of nodes N are?
a) N = 2*L                            
b) N = L + 1
c) N = L – 1                          
d) N = 2*L – 1

d

Explanation: The relation between number of nodes(N) and leaves(L) is N=2*L-1.


Which of the following is false about a binary search tree?
a) The left child is always lesser than its parent
b) The right child is always greater than its parent
c) The left and right sub-trees should also be binary search trees
d) In order sequence gives decreasing order of elements

d

Explanation: In order sequence of binary search trees will always give ascending order of elements. Remaining all are true regarding binary search trees.


What will be the height of a balanced full binary tree with 8 leaves?
a) 8                        
b) 5                        
c) 6                        
d) 4

d

Explanation: A balanced full binary tree with l leaves has height h, where
h = log2l + 1.
So, the height of a balanced full binary tree with 8 leaves =log28+1=3+1=4.


The balance factor of a node in a binary tree is defined as……….
a) addition of heights of left and right subtrees
b) height of right subtree minus height of left subtree
c) height of left subtree minus height of right subtree
d) height of right subtree minus one

c

Explanation: For a node in a binary tree, the difference between the heights of its left subtree and right subtree is known as balance factor of the node.