Track 1 of 4 · 6 short steps
How Computers Actually Work
Goal: Stop treating the computer (and the AI) as magic. Understand bits, memory and what really happens when your code runs.
Why this matters
Every app you build with Lovable, Cursor or Claude eventually turns into instructions a chip follows one at a time, using a limited amount of memory. You don't need to design chips. You do need a rough picture of what's going on underneath, because that picture is what lets you tell a real bug from a fake fix.
The steps
Each step is a 2-minute read with a quick check at the end.
- Step 1
Binary, hex and Boolean logic
- Step 2
The CPU and the execution cycle
- Step 3
Stack vs. heap memory
- Step 4
Compilers and interpreters
- Step 5
Pointers, allocation and memory leaks
- Step 6
Async: the event loop
Try it
Challenge: Spot the bug
Click the line with the bug.
Line 2 is missing await. The toast shows before the insert finishes, and errors are never caught.
AI mistakes to watch for
- Using
as anyor// @ts-ignoreto make a type error disappear instead of fixing the data shape. - Missing
await, so code continues before the database write actually finished. - Mutating objects or arrays in place (e.g.
state.items.push(x)) and wondering why the UI doesn't update. - setInterval / event listeners / subscriptions created in a component with no cleanup, causing slowdowns and duplicate calls.
- Loading an entire table into memory to count or filter it, instead of asking the database to do it.
- Recursive functions with no base case, crashing with a stack overflow on real data.
Tip: paste a file into your AI tool and ask, "Check this for each of these issues and explain any you find." Then verify what it says yourself.
Milestone checklist
Your ticks are saved in this browser only.
Reading & free resources
- Code: The Hidden Language of Computer Hardware and Software (Charles Petzold)The core book for this track. Builds a computer up from light switches. Very readable.
- Harvard CS50x (free)The hands-on milestone. Free lectures, problem sets and an auto-grader.
- Nand2Tetris (free)Optional deep dive: build a computer from logic gates up to a working program.
- MDN: JavaScript memory managementHow garbage collection works in the language most vibe-coded apps use.
- MDN: Using promisesThe clearest explanation of async code and why forgetting
awaithurts. - MIT: The Missing Semester of Your CS Education (free)Terminal, shell, editors, debugging: the tooling nobody teaches.