Using DIV and MOD together (8.1a)
DIV gives how many whole groups fit in the total, MOD gives what is left over. Together they split a total into whole units plus a remainder. E.g. 135 minutes is 2 hours 15.
Understanding Using DIV and MOD together (8.1a) in IGCSE Computer Science Paper 2
What it does: DIV(Total, Size) counts the whole groups. 12 goes into 50 four times, so there are 4 full boxes. MOD gives what is left over: MOD(200, 60) = 20. DIV(200, 60) = 3 is the number of whole hours. DIV(53, 8) = 6 full boxes (48 items) and MOD(53, 8) = 5 items left over.
Common mistakes: Cambridge pseudocode assigns a value with the ← operator, not =. The line should be TotalMinutes ← 135. The items left over after filling the boxes come from MOD, not DIV. DIV gives the number of full boxes. The line should be Left ← MOD(Total, BoxSize).
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 337–346) and word search (Modules 337–357).
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
DIV(Total, Size) and MOD(Total, Size)Fill in the Blanks
Spot the Error
Student with a class code? Join your class →