Boolean Logic
Aligned to the OCR J277 specification
- Topic
- Boolean logic
- Level
- Intermediate
- Reading time
- 6 min
- Published
- 11 June 2026
- Updated
- 1 July 2026
On this page
Key takeaways
- The AND gate outputs 1 only when both inputs are 1; the OR gate outputs 1 when at least one input is 1; the NOT gate inverts a single input.
- OCR J277 requires AND, OR, and NOT only - XOR, NAND, and NOR are outside the scope of this specification.
- For n inputs, a truth table has 2^n rows - list inputs in binary counting order (00, 01, 10, 11) to guarantee all combinations are covered.
- When evaluating a combined logic diagram, add one intermediate column per gate and evaluate left to right, one gate at a time - never try to skip steps.
Studying this for an exam?
Generate a personalised learning path for this subject. Free to get started.
Key terms
- Boolean logic
- A system of logic based on true/false (1/0) values, used at every level of computing from transistors to programming conditions.
- AND gate
- A logic gate that outputs 1 only when both of its two inputs are 1; outputs 0 in all other cases.
- OR gate
- A logic gate that outputs 1 when at least one of its two inputs is 1; outputs 0 only when both inputs are 0.
- NOT gate
- A logic gate (inverter) with a single input that outputs the opposite value: NOT 1 = 0 and NOT 0 = 1.
- Truth table
- A table listing all possible combinations of binary inputs and the corresponding output for a logic expression or gate.
- Logic diagram
- A diagram that shows logic gates connected by lines to represent a Boolean expression visually.
- Boolean expression
- A written formula combining inputs and operations (AND, OR, NOT) that evaluates to a single true/false output, e.g. NOT(A AND B).
- Intermediate column
- An extra column added to a truth table to record the output of each gate in a combined diagram before calculating the final result.
Frequently asked questions
AND outputs 1 only when both inputs are 1 - it is the stricter gate. OR outputs 1 when at least one input is 1, outputting 0 only when both inputs are 0. Swapping these is the most common truth table error.
For 2 inputs you need 2^2 = 4 rows. For 3 inputs you need 2^3 = 8 rows. List inputs in binary counting order starting from 00...0 to make sure every combination is included.
Work left to right, evaluating one gate at a time. Add an intermediate column for each gate's output. Evaluate the intermediate values first, then use those as inputs for the next gate. Never jump straight to the final output.
Generate revision on any topic you study
Type any topic you're studying and Aicademy generates a complete lesson, quiz, and flashcard set, personalised to your level.
Lessons on anything
Structured, level-matched lessons on any topic you study
Practice quizzes
Find out what you actually know before the exam does
Flashcard sets
Lock in key concepts with instant revision cards
Ask Aica
Stuck on something? Get a clear explanation, any time
Testing Programs
Programming Languages and IDEs
Related lessons
6 min
8 min
7 min