Open In App

Data Structures | Binary Search Trees | Question 7

The following numbers are inserted into an empty binary search tree in the given order: 10, 1, 3, 5, 15, 12, 16. What is the height of the binary search tree (the height is the maximum distance of a leaf node from the root)? (GATE CS 2004)
 

(A)



2
 

(B)



3
 

(C)

4
 

(D)

6
 

Answer: (B)
Explanation:

Constructed binary search tree will be.

 

Quiz of this Question
Please comment below if you find anything wrong in the above post

Article Tags :