logo

AQA A-Level Computer Science practice

What is the time complexity of binary search?

Try the question first, then check the answer and practise the same topic again.

At a glance

MCQ

Type

practice

Style

Topic

Searching algorithms

Exam-style question

Try this first

What is the time complexity of binary search?.

  1. A.O(1)
  2. B.O(log n)
  3. C.O(n)
  4. D.O(n²)

Answer and explanation

Concise answer

O(log n)

Why this is correct

Binary search repeatedly halves the part of the list that still needs to be searched, giving a time complexity of O(log n).

Use the concise answer above for a quick check, then reveal the full model answer and detailed explanation.

Common mistake

No common mistake is linked to this question yet.

Related flashcards

No flashcards are published for this page yet.

Related practice questions