Fun computer science · Classes 8 to 10

Logic gates: how computers decide

Every decision a computer makes is built from tiny gates that take 0s and 1s and give back a 0 or a 1. Guess the output first, then test your guess.

1. Meet the gates

Pick a gate and set its two inputs. The lamp shows the output, and the truth table lights up the row you chose. Predict first.

2. A small circuit

Gates can be joined. Choose a circuit, set A, B and C, and see the value after each gate.

Common trap: OR is 1 when at least one input is 1, so it is also 1 when both are. XOR is the one that is 0 when both are 1.

Remember in one minute

Practice now: 3 levels, worked answers, progress tracker →

This is a practice aid made by BodhiScore, not a textbook or an official board resource. Your school’s textbook decides the exact syllabus and the way answers are written. Nothing on this page is saved or sent anywhere. This is a practice aid, not a substitute for your school textbook. These are standard computing facts; where a value depends on a convention (such as 1 KB = 1024 bytes) the question says which one is used.

Share