Level:
Correct: 0
Incorrect: 0
Marks: 0/0
Exam Practice
Course:
Topics:
AQA GCSE Computer Science (Paper 2) Smart practice A mixed round aimed at your weak spots
Unit 1
3.3 Fundamentals of data representation
Unit 2
3.4 Computer systems
Unit 3
3.5 Fundamentals of computer networks
Unit 4
3.6 Cyber security
Fundamentals of cyber security; cyber security threats
Cyber security, its threats and penetration testing
Methods to detect and prevent cyber security threats
Detecting and preventing cyber security threats
Unit 5
3.7 Relational databases and SQL
Unit 6
3.8 Ethical, legal and environmental impacts
Ethical, legal and environmental impacts
Ethical, legal and environmental impacts of technology
Avg
score:
–
Topics
done:
0/22

Boolean logic: gates, truth tables and expressions

Practise 35 exam-style questions on Boolean logic: gates, truth tables and expressions for AQA GCSE Computer Science (Paper 2). Write your answer as you would in the exam and get it marked in seconds against the mark scheme, point by point, with the Study Helper on hand if you get stuck.

  • 35 questions
  • 1–4 marks each
  • Instant marking
  • No sign-up needed
20 questions, marked as you go

Sample questions with model answers

Here are 4 of the questions in this topic, each with a model answer, an explanation of why it earns the marks and the mark scheme an examiner would use.

Question 1

1 mark

Which Boolean expression, written with the symbols . (AND), + (OR), ⊕ (XOR) and an overbar (NOT), means the same as (NOT A) AND (B XOR C)?

Choose your answer.

  • A̅ . (B ⊕ C)
  • A̅ + (B ⊕ C)
  • A̅ . (B + C)
  • A . (B̅ ⊕ C)

Model answer

A̅ . (B ⊕ C)

Explanation

NOT A is written as A̅, AND as . and XOR as ⊕, so (NOT A) AND (B XOR C) becomes A̅ . (B ⊕ C). The other options mix up the symbols: + is OR, not AND or XOR, and in the last option the NOT has moved from A to B. Learning that . is AND and + is OR is essential, because the symbols look like multiplication and addition.

Mark scheme
  1. 1 mark

    A̅ . (B ⊕ C)

    Mark is for AO1 (understanding). If more than one option is given, 0 marks.

Question 2

2 marks

Priya has drawn the logic circuit in the figure. It has three inputs, A, B and C, and one output, X.

Write a Boolean expression for X using the symbols . (AND), + (OR), ⊕ (XOR) and an overbar (NOT). You may type ~ for NOT and (+) for ⊕.

Logic circuit with three inputs, A, B and C, on the left and one output, X, on the right. It has two logic gates (numbered here from left to right, then top to bottom): gate 1 is an XOR gate with inputs A and B; gate 2 is an AND gate with inputs from gate 1 (upper) and input C (lower), and its output is X.

Model answer

X = (A ⊕ B) . C

Explanation

The first gate is XOR with inputs A and B, giving A ⊕ B, and the second gate ANDs that result with C. The brackets matter: without them A ⊕ B . C would be read as A ⊕ (B . C), a different circuit. Check the answer by working through one row, eg A = 1, B = 0, C = 1 gives 1 . 1 = 1.

Mark scheme
  1. 1 mark

    A ⊕ B // B ⊕ A

    All marks AO2 (apply). X = (A ⊕ B) . C // C . (A ⊕ B) scores 2 marks. A. any other expression that gives the same output for every combination of inputs, eg (A . B̅ + A̅ . B) . C, for 2 marks. A. ∧ for . (AND). A. (+) for ⊕ - a site-specific substitute, because ⊕ cannot be typed. R. if words used (eg AND, OR, NOT, XOR). I. Case. I. Brackets that do not change the order of precedence.

  2. 1 mark

    (A ⊕ B) . C - the whole of A ⊕ B, in brackets, ANDed with C

    R. A ⊕ B . C without brackets for this mark, because AND would then be worked out first, giving A ⊕ (B . C).

Question 3

3 marks

The figure shows a truth table for the Boolean expression X = A̅ . B + C, where A̅ means NOT A, . means AND and + means OR.

Complete the truth table by giving the eight values in each of the columns A̅, A̅ . B and X, in order from the top row to the bottom row.

Table with columns "A", "B", "C", "A̅", "A̅ . B", "X". A: 0; B: 0; C: 0; A̅: (blank); A̅ . B: (blank); X: (blank) | A: 0; B: 0; C: 1; A̅: (blank); A̅ . B: (blank); X: (blank) | A: 0; B: 1; C: 0; A̅: (blank); A̅ . B: (blank); X: (blank) | A: 0; B: 1; C: 1; A̅: (blank); A̅ . B: (blank); X: (blank) | A: 1; B: 0; C: 0; A̅: (blank); A̅ . B: (blank); X: (blank) | A: 1; B: 0; C: 1; A̅: (blank); A̅ . B: (blank); X: (blank) | A: 1; B: 1; C: 0; A̅: (blank); A̅ . B: (blank); X: (blank) | A: 1; B: 1; C: 1; A̅: (blank); A̅ . B: (blank); X: (blank).

Model answer

A̅: 1, 1, 1, 1, 0, 0, 0, 0
A̅ . B: 0, 0, 1, 1, 0, 0, 0, 0
X: 0, 1, 1, 1, 0, 1, 0, 1

Explanation

A̅ is 1 in the top four rows, where A is 0, and A̅ . B is 1 only where A̅ and B are both 1 (rows 010 and 011). X is A̅ . B OR C, so it is 1 in those two rows and in every row where C is 1. In this notation AND is done before OR; working out B + C first gives the wrong X column.

Mark scheme
  1. 1 mark

    A̅ column: 1, 1, 1, 1, 0, 0, 0, 0

    All marks AO2 (apply). 1 mark for each column that is completely correct. A. F / FALSE / False / Off instead of 0 and T / TRUE / True / On instead of 1 (not mixed within a column).

  2. 1 mark

    A̅ . B column: 0, 0, 1, 1, 0, 0, 0, 0

  3. 1 mark

    X column: 0, 1, 1, 1, 0, 1, 0, 1

    X = (A̅ . B) + C: the AND is worked out before the OR. R. an X column worked out as A̅ . (B + C), which gives 0, 1, 1, 1, 0, 0, 0, 0.

Question 4

3 marks

Show, by completing the truth table in the figure, that the Boolean expression A . B̅ + A̅ . B gives the same output as A ⊕ B for every combination of the inputs A and B. Here . means AND, + means OR, ⊕ means XOR and an overbar means NOT.

Give the four values in each of the last four columns, from the top row to the bottom row, and state your conclusion.

Table with columns "A", "B", "A . B̅", "A̅ . B", "A . B̅ + A̅ . B", "A ⊕ B". A: 0; B: 0; A . B̅: (blank); A̅ . B: (blank); A . B̅ + A̅ . B: (blank); A ⊕ B: (blank) | A: 0; B: 1; A . B̅: (blank); A̅ . B: (blank); A . B̅ + A̅ . B: (blank); A ⊕ B: (blank) | A: 1; B: 0; A . B̅: (blank); A̅ . B: (blank); A . B̅ + A̅ . B: (blank); A ⊕ B: (blank) | A: 1; B: 1; A . B̅: (blank); A̅ . B: (blank); A . B̅ + A̅ . B: (blank); A ⊕ B: (blank).

Model answer

A . B̅: 0, 0, 1, 0
A̅ . B: 0, 1, 0, 0
A . B̅ + A̅ . B: 0, 1, 1, 0
A ⊕ B: 0, 1, 1, 0
The columns for A . B̅ + A̅ . B and A ⊕ B are the same in every row, so the two expressions always give the same output.

Explanation

A . B̅ is 1 only for A = 1, B = 0, and A̅ . B is 1 only for A = 0, B = 1, so ORing them gives 1 exactly when the inputs are different - which is the definition of XOR. Showing equivalence needs every row of both output columns, not just one example. This is why an XOR gate can be replaced by two NOT gates, two AND gates and an OR gate.

Mark scheme
  1. 1 mark

    A . B̅: 0, 0, 1, 0 and A̅ . B: 0, 1, 0, 0 (both working columns correct)

    All marks AO2 (apply). A conclusion with no truth table values scores 0, because the question asks for the truth table to be completed. A. F / T etc. for 0 / 1.

  2. 1 mark

    A . B̅ + A̅ . B: 0, 1, 1, 0

  3. 1 mark

    A ⊕ B: 0, 1, 1, 0 and a statement that the two output columns are identical (so the expressions are equivalent)

    Both the A ⊕ B column and the conclusion are needed for this mark.

Ready to try the rest? Every answer you write is marked against the mark scheme, so you can see exactly where the marks are.

Study Helper Hints first, answers after you try

Stuck on this one? Ask for a hint and I’ll point you in the right direction, without giving the answer away. Once you’ve checked your answer, I’ll show you how the marks are awarded.