Tip: Choose Save as PDF in the print dialog to download. Use A4 paper size.
Shade in the A or B circle for each question.
Draw a line connecting each item on the left to its match on the right.
| Left column | Right column | |
|---|---|---|
| 1(A AND B) | AX is 1 only when both A and B are 1, as in 'the alarm sounds only if both sensors are on' | |
| 2(A OR B) | B'Neither' needs both inputs to be 0 to give 1, but NAND gives 1 for 0,0, 0,1 and 1,0. It should be NOR. | |
| 3'The door stays locked only if neither the key nor the code is used' means the output is 1 only when both inputs are 0 | CX = A NAND B | |
| 4'The machine works unless both buttons are pressed together' means the output is 0 only when both inputs are 1 | DX = A NOR B | |
| 5'Only one of the two switches is on' -> X = A OR B | E'Only one of' excludes the case where both are on, but OR also gives 1 when both inputs are 1. It should be XOR. | |
| 6'Neither sensor is triggered' -> X = A NAND B | FX is 1 when either A or B is 1, as in 'the light is on if either switch is pressed' |
Complete each line of code by filling in the missing parts.
Shade in the letter of the line that contains an error.
key word = gate — Words in a problem statement point to a gate: both/and = AND, either/or = OR, not = NOT, neither...nor = NOR, not both = NAND, only one of = XOR.Problem: both A and B must be 1
X = A AND BProblem: either A or B is 1
X = A OR BProblem: neither A nor B is 1
X = A NOR BProblem: A and B are not both 1
X = A NAND BProblem: only one of A or B is 1
X = A XOR B