Five-minute card · 0.0 Before we write any code
A computer has no common sense
A program is a recipe. The cook has no common sense.
A cake recipe is a list of exact steps. Crack two eggs. Add 200g of sugar. Mix for thirty seconds. Bake at 180°C for twenty-five minutes. It's written so precisely that anyone following it gets roughly the same cake. That's the point of a recipe. It moves knowledge out of one person's head and into a list of steps.
A program is exactly that — a list of steps, written down, that a machine carries out. The word "code" means those steps written in a language the machine's tools can deal with. Nothing more mysterious than that.
But there is one difference, and it is the difference that will define your next few months. A human following a recipe fills in the gaps. If the recipe says "add the eggs" and you have eggs in shells, you crack them. Nobody wrote "crack them". You just knew.
A computer never fills in a gap. Ever. It does exactly the steps, in exactly the order. And if you left out "crack them"? It puts whole eggs in the bowl and carries on cheerfully. It will not stop and ask. It will not think "hmm, that seems odd".
A bug is a program doing the wrong thing. Almost every bug comes down to this: the recipe said what it said, not what you meant. When something goes wrong later, your first move is never "the computer is broken". It's "what did I actually tell it?"
This is also, weirdly, the good news. A machine with no common sense is also a machine with no moods. It doesn't get bored on step 400. It doesn't do it differently on a Tuesday. Give it the same steps and the same starting point and you get the same result, every single time, forever. That reliability is the thing you'll lean on when you're hunting a bug at midnight.
You write a recipe that says: "Put the pizza in the oven. Set the oven to 200°C. Wait 12 minutes. Take the pizza out." A human follows it and gets a fine pizza. A computer follows it. What happens?