Algorithms that use sequence, branching and iteration together
Most algorithms mix steps in order (sequence), decisions (branch) and repeats (loop). When you read an algorithm, you can label each part and explain it in your own words.
Understanding Algorithms that use sequence, branching and iteration together in Years 5–6 Creating Digital Solutions
What it does: IF ... THEN ... ELSE makes a decision. The algorithm follows only one path, so this is a branch. Step 1 is a sequence. REPEAT 3 TIMES is a loop. IF ... THEN inside it is a branch. So all three parts work together. A sequence is steps in order. Repeats are loops, and decisions are branches. REPEAT means the steps run again, so it is a loop.
Common mistakes: The loop must start with REPEAT, not IF. IF is for a decision (branch). It should be REPEAT 5 TIMES so it matches END REPEAT. This branch runs when the age is under 13, so it should show 'Ask a parent first'. 'You can join' belongs in the ELSE branch.
Free printable worksheet with full answer key — or add this module to a class and your students practise it interactively.
This module's key terms are also in a printable crossword (Modules 21–30) and word search (Modules 21–40).
Take this worksheet further — free with Cloodit
Each concept is reinforced from every angle — learned, then applied, then tested.
Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.
Over 100 of them, across seven natural biomes.
Turns their work into revision material ready for Flash Cards and Exam study.
Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.
Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.
Quick Questions
Match the Pairs
Key Term
sequence, branch, loopFill in the Blanks
Spot the Error
Student with a class code? Join your class →