🔲 Logic Gates

📖 The Physics

Logic gates are the tiny decision-makers inside every digital device (each built from transistors). A gate takes one or two binary inputs (0 = low, 1 = high) and gives a single output.

Each gate follows one fixed rule, summed up in its truth table — the complete list of "for these inputs, this output".

AND: Q = A·B OR: Q = A + B NOT: Q = Ā NAND = NOT(AND) NOR = NOT(OR) XOR = 1 only when inputs differ

Flip the inputs and watch the output bulb. NAND and NOR are called "universal" gates because you can build any other gate — and a whole computer — out of them alone.

🤖 Ask the AI tutor

Ask anything about this simulation and get a simple explanation.

AI can make mistakes — cross-check with your book.