Top | MCQs on Binary Search Algorithm with Answers | Question 8

Last Updated :
Discuss
Comments

Which of the following is correct recurrence for worst case of Binary Search?

T(n) = 2T(n/2) + O(1) and T(1) = T(0) = O(1)

T(n) = T(n-1) + O(1) and T(1) = T(0) = O(1)

T(n) = T(n/2) + O(1) and T(1) = T(0) = O(1)

T(n) = T(n-2) + O(1) and T(1) = T(0) = O(1)

Share your thoughts in the comments