Boolean Logic (AQA GCSE Computer Science)

Exam Questions

27 mins10 questions
11 mark

Complete the truth table for the AND logic gate.

A

B

A AND B

0

0

0

1

1

0

1

1

Did this page help you?

2a1 mark

Complete the truth table for the XOR logic gate.

A

B

A XOR B

0

0

0

1

1

0

1

1

2b1 mark

Figure 3 shows a logic circuit.

Diagram of a logic circuit with inputs A, B, C; gates G1 (AND) and G2 (OR); and output D. A and B connect to G1, G1 and C connect to G2.

State the type of logic gate labelled G1 in Figure 3.

Did this page help you?

33 marks

A game uses three sensors.

A red light (R) in the game switches on if all of the following conditions are true:

  • sensor D is off

  • sensor L is on

  • sensor W is on.

Complete the logic circuit for this game.

You must use the correct symbols for the logic gates.

A rectangle labelled with 'D', 'L', 'R', and 'W' on the sides, likely indicating directional points top, middle left, middle right, and middle bottom.

Did this page help you?

4a1 mark

Draw the logic circuit, using only one logic gate, that is represented by the following truth table:

Input A

Input B

Output Q

0

0

0

0

1

1

1

0

1

1

1

1

Rectangle with points A and B on the left side and point Q on the right side, all points labelled with dots.
4b1 mark

Identify once choice to show the Boolean expression that is equivalent to the logic circuit shown in Figure 6.

Figure 6

Logic circuit diagram with inputs A and B, an inverter, and an AND gate. A is inverted before reaching the AND gate, output is labelled Q.
  • A AND NOT B

  • NOT (A AND B)

  • (NOT A) AND B

  • (NOT A) AND (NOT B)

4c1 mark

Identify one choice to show the Boolean expression which is equivalent to the logic circuit shown in Figure 7.

Figure 7

Logic circuit diagram with inputs A, B, C. Two NOT gates, an OR gate, and an AND gate produce output Q.
  • NOT ((A OR B) AND C)

  • (NOT A) OR ((NOT B) AND C)

  • (NOT (A OR B)) AND C

  • ((NOT A) OR (NOT B)) AND C

Did this page help you?

51 mark

State the type of logic gate shown in Figure 3.

Figure 3

Logic gate symbol representing an OR gate with two input lines on the left and one output line on the right, typically used in digital circuits.

Did this page help you?

13 marks

A logic circuit is being developed for an audio advert in a shop that plays automatically if a customer is detected nearby.

  • The system has two sensors, A1 and A2, that detect if a customer is near. The audio plays if either of these sensors is activated.

  • The system should only play if another audio system, S, is not playing.

  • The output from the circuit, for whether the advert should play or not, is Q.

Complete the logic circuit for this system.

A rectangle with labelled dots on its perimeter; points A1 and A2 on the left edge, point S below them, and point Q on the right edge.

Did this page help you?

22 marks

Write a Boolean expression to show how the output D is calculated from the inputs A, B and C in Figure 3.

You must use the correct symbols for the Boolean operators in your expression.

Logic circuit diagram with inputs A, B, and C. Gate G1 is an AND gate, G2 is an OR gate. Output D is after G2 combining inputs from G1 and C.

Did this page help you?

3a1 mark

A game uses three sensors.

A red light (R) in the game switches on if all of the following conditions are true:

  • sensor D is off

  • sensor L is on

  • sensor W is on

Another circuit in the game will output True if any two sensors are activated or if all three sensors are activated. This has been represented as the Boolean expression:

(W . D) + (D . L) . (W . L)

The expression contains an error.

Identify one choice that shows the expression with the error corrected.

  • (W . D) . (D . L) . (W . L)

  • open parentheses top enclose straight W space. space straight D close parentheses space. space left parenthesis straight D space. space straight L right parenthesis space plus space left parenthesis straight W space. space straight L right parenthesis

  • (W . D) + (D . L) + (W . L)

  • open parentheses straight W with bar on top space. space straight D close parentheses space plus space left parenthesis straight D space plus space straight L right parenthesis space. space left parenthesis straight W space. space straight L right parenthesis

3b3 marks

A green light (G) in the game switches on if all of the following conditions are true:

  • sensor D is off

  • sensor L is off

  • sensor W is on.

Write a Boolean expression for this logic circuit.

You must use Boolean expression operators in your answer.

Did this page help you?

43 marks

Draw a logic circuit for the following scenario.

A sewing machine is running (R) if either the foot pedal is on (F) or the hand dial is on (H) but not both.

You should use only the gates AND, OR and NOT in your answer.

Rectangle with points F and H on the left side, and point R on the right side, evenly spaced along the vertical edges.

Did this page help you?

5a3 marks

A farmer uses an automated system to indicate if soil conditions are right for planting.

The conditions are right for planting if the soil is:

  • warm

  • wet

  • the correct acidity.

Figure 2 shows the logic circuit for this system

Figure 2

Logic circuit diagram with inputs T, M, A. G1 is an AND gate, G2 is a NOT gate, G3 is another AND gate. Outputs are X, Y, and P.

The inputs to the system are:

Soil temperature (T):
0 if the soil is cold
1 if the soil is warm.

Soil moisture (M):
0 if the soil is dry
1 if the soil is wet.

Soil acidity (A):
0 if the soil is the correct acidity
1 if the soil acidity needs adjusting.

The output (P) is:
0 if the conditions for planting have not been met
1 if the conditions for planting have been met.

Complete the truth table for the circuit in Figure 2.

T

M

A

X

Y

P

0

0

0

0

0

1

0

1

0

0

1

1

1

0

0

1

0

1

1

1

0

1

1

1

5b2 marks

The farmer wants to modify the system so that it will indicate that the soil conditions are right for planting if at least one of the three conditions has been met.

Describe changes that could be made to the logic circuit in Figure 2 to allow this to happen.

Did this page help you?