Skip to content

Unit of work

Getting active

Computational thinking, Programming, Sciences | MakeCode | 7-11 yrs

Lesson 2

Using variables in programs


Pupils apply their understanding of variables to record star-jumps and write an algorithm to represent this. They explore a program using variables and debug it so the BBC micro:bit can be used to record an activity.

Learning objectives

  • To write algorithms that use variables
  • To explain how variables are used in programs
  • To debug programs containing variables

You will need

Downloadable resources:

  • Lesson plan
  • Lesson slides
  • HEX files
    • star jump counter
    • variables debug
    • variables debug support
    • variables debug challenge

Other resources:

Whiteboards & dry-wipe marker pens, printouts of slides, MakeCode editor, micro:bits (optional)

Lesson plan