Hands-on drills for Module 1. Each hands you a deceptively simple function and asks you to pin its behaviour — that means: predict exactly what it does, then run it to confirm, and write that confirmed outcome down as a check that runs (a test — a very formalized, precise spec of what the code does). Capturing what code actually does, before you trust it or change it, is the discipline you carry into Module 4 — Refactoring.
- 🟢 Easy · Ask for a table — you prompt, the agent programs: one season of Alpine ski data; ask for the season summary in plain words and read the table the agent builds.
- 🟢 Easy · Predict the behaviour — .NET's
Math.Roundlooks obvious and isn't. Predict eight tricky calls, run to confirm, and pin every surprise. - 🟡 Medium · Characterize, then tame — Exercise 4's ugly-but-working order calculator: pin six behaviours by running it, refactor, and prove the output byte-identical.
- 🔴 Hard · Spec first: the promo engine — a promo engine specified only in prose, with two nasty rule interactions. Write the ~10-assertion battery first, then implement.
Your editable copies are installed with the course — open a drill from Your exercises on the module page and work directly in your own space.