Sikau

Learn How computers work

From bits and logic gates to a CPU you build and program yourself.

Open the box. Learn how numbers, text and fractions become bits; build every logic gate from NAND, then adders, memory and an ALU; and finish with a CPU — fetch, decode, execute, machine code, caches — and an emulator that runs real assembly. Hands-on widgets let you flip bits, wire gates and step a CPU before you code each piece.

Intermediate · 13 lessons · about 8 hours · free

Start How computers work free: run real code in your browserright here

Continue with Google

What you will learn

Unit 1: Bits and numbers

Binary, hex, text, negative numbers and floats.

  1. Day 1Counting in binaryWhy computers use two digits, place values, and converting both ways by hand.30 min
  2. Day 2Hex and textHexadecimal as shorthand for bits, and how UTF-8 turns any character into bytes.35 min
  3. Day 3Negative numbersTwo's complement: how one byte holds −128 to 127, and when addition overflows.35 min
  4. Day 4Fractions and floating pointWhy 0.1 + 0.2 ≠ 0.3, what a float's bits mean, and why money uses integers.35 min
  5. Day 5Project: Number inspectorRead number literals in any base and describe a byte every way at once.35 min

Unit 2: Logic

From NAND gates to adders, memory and an ALU.

  1. Day 6Logic gatesAND, OR, NOT, XOR — and building every one of them from NAND alone.35 min
  2. Day 7Adding with gatesHalf adders, full adders and a 4-bit ripple-carry adder.40 min
  3. Day 8Memory: clocks and registersHow a circuit remembers: rising clock edges, registers and counters.35 min
  4. Day 9Project: A 4-bit ALUOne unit that adds, subtracts and does logic, with zero, negative and carry flags.45 min

Unit 3: The CPU

Fetch–decode–execute, machine code, caches and an emulator.

  1. Day 10Fetch, decode, executePrograms live in memory; a program counter and a loop bring them to life.40 min
  2. Day 11Programming the machineLoops, multiplication and Fibonacci in machine instructions.40 min
  3. Day 12Memory hierarchy and cachesWhy the order you read memory in can make code 10× faster.40 min
  4. Day 13Capstone: A CPU emulatorAn assembler with labels and comments, plus a machine with a stack, CALL and RET.60 min

Before you start

These courses make How computers work easier:

See all courses

Built with ❤️ by dibe.sh