Question
An insert(root, value) function for a Binary Search Tree
(BST) is implemented recursively. After inserting several elements, a search(root, value) function correctly finds most values, but fails to find some values that were definitely inserted. Upon inspection, it's found that the insert function sometimes creates a new node but doesn't correctly link it to its parent. Which of the following is a common mistake in a recursive BST insertion that could cause this?Solution
The correct answer is C
1140, ?, 1130, 1160, 1120, 1170
- 6, ?, 9816, 9825, 19429, 19438
What will come in place of the question mark (?) in the following series?
55,...
124, 180, 108, 198, ?, 220
216, 81, 297, 378, ?, 1035, 1728
110, 156, 212, ?, 354, 440
Find the missing number in the given number series.
8, 13, ?, 23, 28, 33
In each of the following series, one term is missing. Find the missing term.
7, 11, 19, 35, 67, ?
864, 432, 144, ? , 7.2, 1.2
69, 35.5, 39.5, 68.25, 152.5, ?