🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Binary Search Quiz: all 8 questions

Binary Search Quiz · Question 1 of 8

About how many comparisons does binary search need on 1,000,000 sorted numbers?

About how many comparisons does binary search need on 1,000,000 sorted numbers?

  1. A.About 1,000
  2. B.About 1,000,000
  3. C.About 20
  4. D.About 500,000
Answer & explanation

Correct answer: About 20

log₂(1,000,000) ≈ 20, because each comparison halves the remaining range.

Can you get the rest right without peeking?

Take the timed Binary Search Quiz quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →