Let A be a sorted array containing 1000 distinct integers. You perform a recursive binary search on A to find an element . Suppose each comparison checks whether the middle element computed during the current recursive step is equal to, less than, or greater than . The maximum number of comparisons that may have to be performed if is not an element of A is _______ . (Answer in integer)
GATE DA 2026 — Question 31
Programming, Data Structures and AlgorithmsSearch algorithms: linear search and binary searchNAT1 markMedium
A GATE question every morning
One real past-paper question every morning for your branch, answer hidden until you tap. Free on Telegram.

