Year 8 – Computing systems Learner activity sheet
Lesson 4 – It’s only logical
Logic circuits – Solutions
For the tasks below, you will need to open a browser window and visit
circuitverse.org/simulator.
Task 1 . A circuit with the AND logic gate
The AND gate
1. Go to ‘Circuit elements’ on the left.
2. Click on Gates.
3. Click on the AND gate.
4. Place an AND gate on the canvas.
The inputs to the AND gate
5. Go to ‘Circuit elements’ on the left.
6. Click on Input.
7. Click on the ‘Input’ box.
8. Place an input box on the canvas, to the
left of the AND gate.
9. Repeat steps 7–8 to add a second input.
The output of the AND gate
10. Go to ‘Circuit elements’ on the left.
11. Click on Output.
12. Click on the ‘Output’ box.
13. Place an output box on the canvas, to
the right of the AND gate.
14. Click on the ‘Digital LED’.
15. Place an LED on the canvas, to the right
of the AND gate.
Page 1 Last updated: 25/03/2021
Year 8 – Computing systems Learner activity sheet
Lesson 4 – It’s only logical
The output of the AND gate
16. Connect the first input box to one of the
inputs of the AND gate (by click-
dragging on the connectors, i.e. the little
green circles).
17. Connect the second input box to the
other input of the AND gate.
18. Connect the output of the AND gate to
the output box.
19. Connect the output of the AND gate to
the digital LED.
You can flip an input from false (0) to true (1) and vice versa by clicking on the input box.
Verify that the output is true (1) and the light is turned on only when both of the inputs
are true (1). The table below contains all the input combinations that you should try.
first input second input AND output
A B A and B
false false false
false true false
true false false
true true true
Task 2 . A new logic gate
Create the logic circuit below.
This is identical to the logic circuit that you created in the previous task, except that the
AND logic gate has been replaced with an XOR logic gate. This is a new logic operation.
Page 2 Last updated: 25/03/2021
Year 8 – Computing systems Learner activity sheet
Lesson 4 – It’s only logical
You can flip an input from false (0) to true (1) and vice versa by clicking on the input box.
Try all the input combinations in the table below and fill in the table with the
corresponding output.
first input second input XOR output
A B A xor B
false false false
false true true
true false true
true true false
Before, we described how the result of the OR operator is true if at least one of its inputs
is true. How would you describe the result of the XOR logic operator with words?
The result of the XOR operator is true if exactly one of its inputs is true.
Task 3 . Security light
For the logic circuit below, there is a single combination of input values that will turn on
the output LED.
You can use logical reasoning to deduce what this combination will be, or you can create
the circuit and try out the different combinations of input values. Write your answer in
the table below, and provide a brief explanation for your answer.
input input output
motion light
true false true
Explanation:
Page 3 Last updated: 25/03/2021
Year 8 – Computing systems Learner activity sheet
Lesson 4 – It’s only logical
In order for the output to be true, both of the inputs of the AND gate must be true. The first input to
the AND gate is motion, so motion must be true. The second input to the AND gate is the inverse of
light, so the inverse of light must be true. Therefore, light must be false.
Explorer question: What is the logical expression that describes the output of this circuit?
The logical expression is motion and (not light).
Explorer task . Adding binary digits
Create the logic circuit below. This is called a half-adder: it adds together two binary
digits.
Try setting the input bits to all four possible combinations and write down the binary
result, to verify that it is correct.
Note: As you can see in the image above, the binary result has two digits, so your answer must
also contain two digits.
0 0 1 1
+ 0 + 1 + 0 + 1
00 01 01 11
010 110 110 210
Resources are updated regularly — the latest version is available at: ncce.io/tcc. This resource is licensed
under the Open Government Licence, version 3. For more information on this licence, see ncce.io/ogl.
Page 4 Last updated: 25/03/2021