Skip to main contentSkip to solution

Which of the following are the applications of binary search?

(A) Telephone Directory

(B) Finding the element with a minimum or maximum value in a sorted list

(C) Implementing routing tables

(D) Indexing in database

Solution

✅ Correct Option: 3

Binary search repeatedly halves a sorted collection, so it fits any task that looks up or locates items in sorted data. All four listed uses fit this.

ApplicationHow binary search is used
(A) Telephone directoryNames are sorted alphabetically, so a name is found by repeatedly halving the list
(B) Min or max in a sorted listHalving the sorted (or rotated sorted) list locates the smallest or largest value
(C) Routing tablesSorted address or prefix entries are searched to find the matching route
(D) Database indexingIndexes keep keys in sorted order, so a key is located by halving the index

The common condition is that the data must be sorted.

Keyboard Shortcuts

  • Left arrow: Previous question
  • Right arrow: Next question
  • S key: Jump to solution
  • Q key: Jump to question