GCSE – Lesson 12 – While loops

Curriculum KS4 Unit Lesson

This lesson allows learners to find out about using iteration in their programs. It will define iteration, give a code walkthrough of a while loop, and then use a ‘guess the number’ game as a practical example for using iteration. Live coding will be used to turn an if statement into a while loop, and learners will be given a series of challenges to extend the ‘guess the number’ game using programming skills that they have gained during this course.

Learning objectives

  • Define iteration as a group of instructions that are repeatedly executed
  • Modify a program to incorporate a while loop

Package contents

  • Lesson plans
  • Slide decks
  • Learner resources
  • Homework