Given an array arr = {45,77,89,90,94,99,100} and key = 99; what are the mid values(corresponding array elements) in the first and second levels of recursion?
A. 90 and 99
B. 90 and 94
C. 89 and 99
D. 89 and 94
Answer:A
Given an array arr = {45,77,89,90,94,99,100} and key = 99; what are the mid values(corresponding array elements) in the first and second levels of recursion?
A. 90 and 99 B. 90 and 94 C. 89 and 99 D. 89 and 94
Explanation: Trace the input with the binary search recursive code.