Using the FOR counter inside the loop
Uses the FOR counter inside the loop body. Count holds a new value on each repeat, so this outputs a times table. Never change Count inside the loop; after the loop it keeps its last value.
Understanding Using the FOR counter inside the loop in IGCSE Computer Science Paper 2
What it does: The body only reads Count to output a calculation and never assigns a new value to it, which is the correct way to use the counter. Count starts at 1 and goes up by 1 on each repeat, so OUTPUT Count shows 1, then 2, then 3. On repeat 1 Count is 1, so 1 * 7 = 7. On repeat 2 Count is 2, so 2 * 7 = 14. On the 3rd repeat Count holds 3, so Count * 7 = 21. FOR...NEXT updates the counter for you. Writing your own update in the body is a mistake.
Common mistakes: The FOR loop gives the counter its start value with the assignment arrow <-, not =. It should be FOR Count <- 1 TO 5. The loop counter is called Count, so Counter is a different variable that was never given a value. It should be OUTPUT Count * 7.
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 379–388) and word search (Modules 379–398).
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
OUTPUT Count * 7Fill in the Blanks
Spot the Error
Student with a class code? Join your class →