logo

AQA A-Level Computer Science practice

A solution uses two Boolean inputs, A and B. What is the best way to check that its output is correct for every possible input combination?

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

At a glance

MCQ

Type

practice

Style

Topic

Abstraction and automation

Exam-style question

Try this first

A solution uses two Boolean inputs, A and B. What is the best way to check that its output is correct for every possible input combination?.

  1. A.Test only when A and B are both true
  2. B.Test only when A and B are both false
  3. C.Test one randomly selected input combination
  4. D.Test all four combinations of A and B

Answer and explanation

Concise answer

Test all four combinations of A and B

Why this is correct

Two Boolean inputs have 2 × 2 = 4 possible combinations. Testing every combination checks the complete input space for this simple problem.

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