1. Try the switches
Here 0 means off (false), and 1 means on (true). Our lamp is a toy output indicator, not a real railway safety signal. This is a logic puzzle, not an electrical wiring guide.
The highlighted row is the current input. A truth table lists every possible input combination and its output.
2. Predict without touching the switches
These questions are separate from the experiment above. Choose an output, then check your reasoning. A wrong answer can be retried; each question earns at most one point.
3. Spot the important difference
- AND: both A and B must be 1.
- OR: at least one is 1, including when both are 1. This is inclusive OR.
- XOR: exactly one is 1. When both are 1, the output is 0.
- NOT: just one input. NOT 0 is 1; NOT 1 is 0. B is unused, so its switch is disabled.
Invent a rule
A toy station sign lights up if either of two buttons is pressed, including both together. Which gate fits? How would your answer change if pressing both must turn the sign off?
Computers can combine many logic gates. This lab models only the yes/no rules, not voltage levels, timing or a complete computer.
No account, saved scores or input uploads. Reloading starts over.