Skip to content
Menu

Year 3 (ages 7–8, Grade 2 in the US) · Computing · Sequences in Scratch · Lesson 4

Events

Using events (green flag, key presses, sprite clicks) to start scripts in block-based programs, and planning interactive controls.

Exam boards: this lesson matches the AQA and Pearson Edexcel GCSE computing courses. Check which course your school follows.

Whiteboard video lesson: Events

13-minute video lesson

Teaching, worked examples and 20 practice questions solved step by step.

Watch free for a month

What your child will learn

  • Define an event
  • Read event-driven scripts
  • Write key-control scripts
  • Test and debug events

The method

  1. Choose event.
  2. On top.
  3. Actions.
  4. Test.

Key words: event, script, sprite, key press, click, block coding.

Worked examples

Worked examples from the lesson, with every step.

Question 1

When does this code run?

  1. Step 1: Read the code
  2. Step 2: hat block

Answer: when the green flag is clicked

Question 2

When does this code run?

  1. Step 1: Read the code
  2. Step 2: hat block

Answer: when the up arrow key is pressed

Question 3

What does this code do?

  1. Step 1: Read the code
  2. Step 2: y = up/down

Answer: moves the sprite up by 10