Cambridge AS Level Computer Science 9618 · 3.2 Logic Gates and Logic Circuits

Q64 · 9618/12/O/N/25 Q9

Worked solution from the Hardware Paper 1 Theory Fundamentals booklet, Part 2 of 2.

Q649618/12/O/N/25original Q9Structured · 4 marks
Question 9 from 9618/12/O/N/25

Worked solution

(a)

Work from the inputs to the output, one gate at a time. Do not simplify.

A and B go into an XOR gate, and its output goes into a NOT gate: NOT (A XOR B) [1]

B and C go into an AND gate, and its output goes into an OR gate with A: (B AND C) OR A. The NOT output and this OR output go into the final NAND gate [1]

Write: X = (NOT (A XOR B)) NAND ((B AND C) OR A)

The two inputs of the NAND gate can be written in either order.

(b)

Work out each row. Remember NOT A OR NOT C is the same as A NAND C.

Row 2 (A=0, B=0, C=1): A NAND B = 1 and NOT A OR NOT C = 1. They are the same, so XOR gives 0 and X = 1. The table says 0, so row 2 is wrong.

Row 4 (A=0, B=1, C=1): A NAND B = 1 and NOT A OR NOT C = 1. XOR gives 0 and X = 1. The table says 0, so row 4 is wrong.

Row 7 (A=1, B=1, C=0): A NAND B = 0 and NOT A OR NOT C = 1. XOR gives 1 and X = 0. The table says 1, so row 7 is wrong.

Write the two or three wrong rows: Row 2, Row 4, Row 7. One correct or two correct rows score [1]

All three correct rows score the second mark [1]

KEY IDEABuild the expression gate by gate from the inputs to the output, and check a truth table one row at a time using the inner brackets first.
TOTAL 4 marks

Official mark scheme

Mark scheme for 9618/12/O/N/25 question 9
VIDEO
▶ Topic lesson

A lesson on this topic · by ZAINEMATICS. Tap the picture to open it on YouTube.

Solutions follow the official Cambridge mark schemes; marks are shown in grey. Videos are from other YouTube channels. Paper codes read component / series / year: M/J = May/June, O/N = October/November. Past-paper questions © UCLES, reproduced for classroom practice.