Skip to topic
    ← Back to course topics

    Truth tables — Edexcel GCSE Computer Science

    Test yourself on Truth tables with PEARSON EDEXCEL GCSE practice questions.

    Start free

    7 days Premium · Then free forever · No card, no charge

    Truth tables explained

    This topic focuses on the application of logical operators (AND, OR, NOT) within truth tables to solve computational problems.

    Read the full explanation

    Students are required to construct and interpret truth tables involving up to three inputs to determine the logical output of a system.

    Read the Truth tables study guideFull revision notes for Edexcel GCSE Computer Science

    What to demonstrate

    1. Correct application of AND, OR, and NOT operators
    2. Accurate completion of truth tables with up to three inputs
    3. Correct identification of output values based on input combinations

    Truth tables exam tips

    Topic Overview

    Truth tables are a fundamental tool in computer science used to determine the output of logic gates and Boolean expressions. They list all possible combinations of inputs (usually 0 and 1, representing FALSE and TRUE) and show the corresponding output for each combination. In the Edexcel GCSE Computer Science specification, truth tables are essential for understanding how circuits process binary data, forming the basis of decision-making in computers. Mastery of truth tables allows you to analyse and design simple logic circuits, which is crucial for topics like binary arithmetic, control systems, and programming conditions.

    Truth tables directly support the study of Boolean algebra, where expressions like A AND B, A OR B, and NOT A are evaluated. They also help in simplifying logic circuits, reducing the number of gates needed, which is important for efficient hardware design. In the wider curriculum, truth tables connect to binary representation, data storage, and the fetch-execute cycle. Understanding them is not just about memorising patterns; it's about developing logical thinking and problem-solving skills that are applicable across computer science.

    For your GCSE exam, you will be expected to construct truth tables for given logic circuits, write Boolean expressions from truth tables, and identify equivalent circuits. Questions often involve combining multiple gates (AND, OR, NOT) and may include NAND, NOR, and XOR gates. A solid grasp of truth tables will help you tackle these questions confidently and avoid common pitfalls.

    Key Concepts
    • →Logic gates: AND (output 1 only if both inputs are 1), OR (output 1 if at least one input is 1), NOT (inverts input), NAND (opposite of AND), NOR (opposite of OR), XOR (output 1 if inputs are different).
    • →Input combinations: For n inputs, there are 2^n possible combinations. List them in binary order (e.g., 00, 01, 10, 11 for two inputs).
    • →Boolean expressions: Represent logic circuits algebraically, e.g., A AND B is written as A·B or AB; A OR B as A+B; NOT A as ¬A or A'. Truth tables evaluate these expressions for all input combinations.
    • →Truth table structure: Columns for each input, then intermediate outputs (if circuit has multiple gates), and finally the final output. Each row corresponds to one input combination.
    • →Equivalence: Two circuits are equivalent if they have the same truth table. This is used to simplify circuits using Boolean algebra laws (e.g., De Morgan's laws).
    Marking Points
    • Correct application of AND, OR, and NOT operators
    • Accurate completion of truth tables with up to three inputs
    • Correct identification of output values based on input combinations
    Examiner Tips
    • 💡Ensure all possible combinations of inputs are accounted for in the truth table
    • 💡Double-check the logic of each operator before filling in the output column
    • 💡Practice constructing tables for three inputs to ensure familiarity with the 8-row structure
    • 💡Tip 1: Always label your columns clearly, including intermediate outputs if the circuit has multiple gates. This shows your working and can earn you method marks even if the final answer is wrong.
    • 💡Tip 2: Double-check the number of rows: for n inputs, you need 2^n rows. A common mistake is to miss a row, especially with three inputs (8 rows). Use a systematic approach: start with all inputs at 0, then increment like binary counting.
    • 💡Tip 3: For circuits with multiple gates, work step by step. For example, if you have (A AND B) OR (NOT C), first compute A AND B, then NOT C, then OR those results. This reduces errors and makes your logic clear.
    Common Mistakes
    • Misconception: The output of an OR gate is 1 only when exactly one input is 1. Correction: OR gate outputs 1 when at least one input is 1, including both inputs being 1. The exclusive OR (XOR) gate is the one that outputs 1 only when inputs are different.
    • Misconception: NOT gate can have multiple inputs. Correction: NOT gate has only one input and one output. It simply inverts the input. For multiple inputs, you need separate NOT gates or other gates.
    • Misconception: When constructing truth tables, the order of input combinations doesn't matter. Correction: Always list combinations in binary order (e.g., 00, 01, 10, 11) to avoid missing any and to make it easier to check. Examiners expect this order.
    Frequently Asked Questions
    How do I construct a truth table for a logic circuit with three inputs?
    For three inputs (A, B, C), there are 2^3 = 8 possible combinations. List them in binary order: 000, 001, 010, 011, 100, 101, 110, 111. Then, for each combination, evaluate the output of each gate in the circuit step by step. For example, if the circuit is (A AND B) OR (NOT C), first compute A AND B for each row, then NOT C, then OR those two results. Write intermediate columns to show your working.
    What is the difference between OR and XOR gates?
    An OR gate outputs 1 if at least one input is 1, so it outputs 1 for combinations 01, 10, and 11. An XOR (exclusive OR) gate outputs 1 only if the inputs are different, so it outputs 1 for 01 and 10, but 0 for 00 and 11. In Boolean algebra, OR is written as A+B, while XOR is often written as A ⊕ B. Remember: OR is inclusive, XOR is exclusive.
    How do I write a Boolean expression from a truth table?
    Identify the rows where the output is 1. For each such row, write a product term (AND) that is true only for that row. For example, if output is 1 when A=1, B=0, the term is A AND NOT B (A·¬B). Then combine all these product terms with OR. So if output is 1 for rows 01 and 10 (with inputs A,B), the expression is (¬A·B) + (A·¬B), which is actually XOR. Simplify if possible using Boolean algebra.
    What are De Morgan's laws and how do they relate to truth tables?
    De Morgan's laws state that NOT (A AND B) = (NOT A) OR (NOT B) and NOT (A OR B) = (NOT A) AND (NOT B). These laws are used to simplify Boolean expressions and to show equivalence between circuits. You can verify them using truth tables: construct a table for both sides of the equation and check that the outputs match for all input combinations. This is a common exam question.
    Can truth tables have more than one output?
    Yes, a logic circuit can have multiple outputs. For example, a half adder has two outputs: sum and carry. In such cases, you construct a truth table with columns for each output. Each output is evaluated separately based on the same inputs. For the half adder, with inputs A and B, the sum output is A XOR B, and the carry output is A AND B.
    How do I handle NOT gates in a truth table?
    A NOT gate has one input and one output that is the opposite. In a truth table, if you have a NOT gate acting on input A, create a column for NOT A (or A') and simply invert the A values: if A=0, NOT A=1; if A=1, NOT A=0. If the NOT gate is after another gate, first compute the intermediate output, then invert it. Always include intermediate columns to avoid mistakes.