Control Flow
Map
Arrows point from what you learn first to what it opens. Point at a concept to light up its chain and where it comes back deeper. Right-click a concept (or press and hold it) for its lessons and stories.
- Proven to depth123
- Open
- Locked
- Comes back deeper
Learning path
In the order the concepts build on each other.
- BooleansLockedThe two values True and False - what a comparison like a == b gives back, and what a program decides with.Opens after: Return values
- ConditionalsLockedCode that runs only when a condition is true - if, else, switch - letting a program make decisions.Opens after: Booleans
- LoopsLockedRepeating a block of code - a fixed number of times, while a condition holds, or over each element of a collection.Opens after: Conditionals
- Accumulator patternLockedKeeping one name outside a loop - a total, a count, a largest so far - and updating it every round, so the loop remembers something about every value it has seen.Opens after: Loops
Connections to other domains
- Conditionals leads to The yearThe Sky
- Conditionals, depth 2 needs Conditional statementsLogic
- Loops, depth 2 needs RecursionFunctions
- Conditionals leads to RecursionFunctions
- Loops leads to AlgorithmAlgorithms
- Booleans needs Return valuesFunctions
- Loops leads to Iterators and generatorsData Structures
- Loops leads to ListsData Structures
- Accumulator pattern leads to Floating-point numbersData Types
- Conditionals leads to Edge casesWriting Correct Code