Defining a procedure with one parameter
Defines a procedure with one parameter. In the brackets after the name, write the parameter identifier, a colon, then its data type. Size is used inside the body.
Understanding Defining a procedure with one parameter in IGCSE Computer Science Paper 2
What it does: Inside the body between PROCEDURE and ENDPROCEDURE, the parameter name Size is used like a variable to output its value. The parameter identifier comes first, then a colon, then the data type: Size : INTEGER. A procedure starts with PROCEDURE and finishes with ENDPROCEDURE. ENDFUNCTION is for functions.
Common mistakes: The parameter is called Size, so the loop must use Size. Length is not defined anywhere. It should be FOR Count ← 1 TO Size. A procedure must finish with ENDPROCEDURE. ENDFUNCTION is used to close a function.
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 399–408) and word search (Modules 399–418).
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
PROCEDURE Line(Size : INTEGER)Fill in the Blanks
Spot the Error
Student with a class code? Join your class →