GCSE Computer Science: Boolean Logic

Boolean logic appears on every GCSE Computer Science specification, and the marks usually go on small slips: a NOT placed over the wrong input, a bracket missing from an expression, or a truth table with rows in the wrong order. This material trains the whole topic step by step, based on the DfE GCSE subject content for computer science, which asks for Boolean logic using AND, OR and NOT, combinations of these, and the use of truth tables to solve problems.

The quiz has twelve questions. It starts with the size of a truth table (two to the power of the number of inputs) and the single gates, including XOR, which is named on some specifications, for example AQA's, and not on others. It then moves to what exam questions actually ask: completing the output column of a three-input circuit such as (A AND B) OR C, finding which set of inputs makes an expression true, and writing the expression for a circuit. Because no diagram is shown, each circuit is described in words, gate by gate, which is also good practice for reading a logic diagram carefully. Three questions turn everyday situations into logic: a shop alarm with a silent mode, a heating system with a boost button and a Python function that decides who may enter a climbing wall. The last question builds the 'exactly one input' rule from AND, OR and NOT alone.

Every explanation shows the working: which part of the expression to evaluate first and why each wrong option fails. The flashcards cover the gate definitions, the standard truth-table columns, the row rule and the words in a scenario that signal AND, OR and NOT.

The written work has eight longer tasks to answer on paper: completing a full three-input truth table, writing and evaluating an expression from a described circuit, designing expressions for a greenhouse vent, a log-in check and a car's seat-belt buzzer, comparing OR with XOR, explaining why a fourth input doubles the table, and proving that NOT (A AND B) matches (NOT A) OR (NOT B). Each task comes with a model answer and the points a marker would look for.

There is also a short oral practice with an examiner, who asks one question at a time, describes circuits in words and gives brief feedback at the end. The material suits Year 10 and Year 11 students revising for the computer systems or programming paper, whichever board they sit, and anyone who wants to check that they can build a truth table without guessing.

  • State the truth tables of NOT, AND and OR, and of XOR where the specification includes it
  • Complete the output column of a truth table for a circuit with up to three inputs
  • Write the Boolean expression for a circuit described gate by gate
  • Evaluate an expression for a given set of inputs, working brackets first
  • Turn a real situation into an expression using AND, OR and NOT
  • Use Boolean operators correctly in program conditions

Practice material written by Zestly, based on the DfE GCSE subject content for computer science (Boolean logic using AND, OR and NOT, combinations of these, and truth tables), with XOR as listed in the AQA GCSE Computer Science specification (8525).

Sample question

The output of a circuit is P = (A OR B) AND (NOT C). For which set of inputs is P equal to 1?

See the answer

A = 0, B = 1, C = 0

P is 1 only when (A OR B) is 1 and NOT C is 1, i.e. at least one of A and B is 1 and C is 0. A = 0, B = 1, C = 0 gives (0 OR 1) AND (NOT 0) = 1 AND 1 = 1. With A = B = 0 the bracket is 0; with C = 1, NOT C is 0.

← Computer Science

↑ GCSE