Maths quiz algorithm with harder and easier questions
An algorithm that repeats questions, adds 1 to a score variable for each right answer, and picks harder or easier questions depending on that score.
Understanding Maths quiz algorithm with harder and easier questions in ACARA Digital Technologies Years 5–6
What it does: A loop with a stopping condition makes the quiz repeat. It stops when the count of questions reaches 5. The counter variable needs a starting value. 0 means no right answers yet. Adding 1 to score each time keeps count of the correct answers. Setting it to 0 would wipe out the count. A quiz repeats the 'ask and check' steps. That repeating is iteration. IF ... THEN is branching. The algorithm picks a different path depending on whether the condition is true. Set the score to 0 once at the start. If it were reset inside the loop, the score would never grow past 1.
Common mistakes: The score should go up when the answer is right. The line should be IF answer is right THEN, so that score ← score + 1 only runs for a right answer. The student has not answered anything yet, so the wrong counter must start at 0. It should be wrong ← 0.
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 120–132) and word search (Modules 106–132).
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
quiz algorithmFill in the Blanks
Spot the Error
Student with a class code? Join your class →