Choose exam board for KS4 Computer Science (GCSE)
Choose exam board for KS4 English
Choose exam board for KS4 French
Choose exam board for KS4 Geography
Choose exam board for KS4 German
Choose exam board for KS4 History
Choose tier for KS4 Maths
Choose exam board for KS4 Music
Choose exam board for KS4 Physical education (GCSE)
Choose exam board for KS4 Religious education (GCSE)
Choose exam board for KS4 Spanish

      Procedures in programming

      Lesson details

      Learning outcome

      I can decompose a task into small steps.

      Key learning points

      1. Actions have 'chunks' within everyday sequences.
      2. A computer can repeatedly call a procedure.
      3. Programs can use procedures.

      Keywords

      • Decompose - to break down a task into smaller, more achievable steps

      • Procedure - a named set of commands that can be called multiple times throughout a program

      Common misconception

      The computer understands procedure names and knows what to do based on the chosen name.

      The name is for humans, the computer only follows the instructions inside the procedure.

      Teacher tip

      A subroutine is a sequence of commands to perform a specific task with an identifiable name. Consider how we use this in real life. A general instruction of 'walk to school' contains contains many different instructions followed such as "walk to end of road", "turn right", etc.

      Equipment

      Pupils need access to a device with software that can execute Logo programs. Examples in this lesson use FMSLogo https://oak.link/fms-logo

      Licence

      This content is © Oak National Academy Limited (2026), licensed on Open Government Licence version 3.0
      except where otherwise stated. See Oak's terms & conditions
      (Collection 2).

      Lesson video

      Loading...

      Prior knowledge starter quiz

      6 Questions

      Q1.
      What is a program?

      Correct answer: a set of ordered commands that a computer can run
      a single command to control a computer
      a shape that moves on the screen
      a sequence of repeated patterns

      Q2.
      What is a command in programming?

      a precise sequence of steps
      Correct answer: a single instruction in a program
      a repeated pattern in a loop
      a shape that draws lines

      Q3.
      What is an algorithm?

      Correct answer: a precise sequence of steps to complete a task
      a small shape that moves and draws on the screen
      a repeated section of code
      a single instruction in a program

      Q4.
      What does the term "debug" mean in programming?

      to create an algorithm
      to repeat a section of code
      to design a new program
      Correct answer: to find and fix errors in a program

      Q5.
      What is a count-controlled loop?

      a shape that moves on the screen
      a sequence of repeated patterns
      Correct answer: a section of code that runs a certain number of times
      a single command in a program

      Q6.
      What command would you use to draw a square with a screen turtle? Use the repeat command and sides of 100 steps.

      Correct Answer: repeat 4 [fd 100 rt 90], repeat 4 [rt 90 fd 100]

      6 Questions

      Q1.
      Put these steps of decomposition in order.

      1 - Break the task into smaller steps.
      2 - Write an algorithm for the smaller steps.
      3 - Translate the algorithm into code.

      Q2.
      What is a procedure in programming?

      a single command that is used once
      Correct answer: a named set of commands that can be reused
      a loop that repeats a command
      a step-by-step sequence of instructions

      Q3.
      Match the terms with their definitions.

      Correct Answer:decompose,to break down a task into smaller steps

      to break down a task into smaller steps

      Correct Answer:procedure,a named set of commands that can be reused

      a named set of commands that can be reused

      Correct Answer:debug,to find and fix errors in a program

      to find and fix errors in a program

      Q4.
      Order these steps for using a procedure in a program.

      1 - Create a procedure.
      2 - Call the procedure in the program.
      3 - Run the program.

      Q5.
      What of these statements about a procedure is correct?

      The name must include numbers to work.
      Correct answer: The name is only for humans, the computer only follows the instructions.
      The name must match the algorithm exactly.
      The computer understands the name and acts accordingly.

      Q6.
      Write the command to create a new procedure called square.

      Correct Answer: to square

      To help you plan your 4 computing lesson on: Procedures in programming, download all teaching resources for free and adapt to suit your pupils' needs...