Debugging worksheet for Years 3–6: Bug hunt

Members Chapter 6 of Make Your Own Game: Code a Catching Game with Hazel · Year 3, Year 4, Year 5 · 3 pages · PDF, A4

All 7 worksheets in this game

One for each chapter

Bug Hunt is a printable debugging worksheet for Years 3 to 6 (ages 7 to 11) that teaches children to test a game, explain what is going wrong, find the block causing it and fix it. It follows the KS2 computing national curriculum in England: design, write and debug programs, and use logical reasoning to detect and correct errors in algorithms and programs.

  • 3 A4 pages
  • Answers sheet
  • About 30 minutes
  • Colour or black and white
  • National curriculum

For members Membership opens every worksheet and every game. Already a member? Log in

Start with the free one: Plan a game (chapter 1).

The game for this worksheet Make Your Own Game: Code a Catching Game with Hazel Chapter 6 · Debugging: test, find and fix bugs in a game · read aloud ▶ Play chapter 6 in the gameChapter 1 is free

Print it on A4, in colour or black and white. Do it after the chapter, or before it to see what your child already knows.

What's on the worksheet

Debug a catching game: test it, say exactly what goes wrong, find the block causing it, fix it and test again. Includes a smiley-face instructions bug hunt at home, and answers.

Page 1 · Learn
Flip explains bugs and the test, spot, find, fix cycle, then a worked example fixes a basket that moves the wrong way. A warm-up puts the debugging steps in order.
Page 2 · Try it together
Face bug hunt: your child writes 5 steps to draw a smiley face, a grown-up follows them exactly, then you spot, find and fix the bugs and swap.
Pages 2–3 · Practise
Match four bugs to their causes, fix a timer that counts up, choose the fix that works and find which script makes the basket jump too far. Then a challenge about testing again.
Answers sheet
Every answer by page, what to watch out for (misreading what goes wrong, blaming the wrong block, a fix that doesn't work) and quick ideas.

3 A4 pages and an answers sheet · about 30 minutes

Using it at home

  • In Face bug hunt, follow the instructions exactly, even if the face looks silly: it shows why computers need precise steps.
  • When something goes wrong at home, use the same words: test, spot, find, fix.

Watch out for

Mixing up what is actually going wrong when the game runs.
Test it and describe it exactly, such as "the basket moves right when I press left", not "it's broken".
Picking a block that is not causing the problem.
Ask "Which script controls the thing that goes wrong?" and look there first.
Choosing a change that does not fix the problem.
Always test again after a fix. If it still goes wrong, go back round the cycle.

Questions from the worksheet

  1. Draw a line from each bug to what is causing it, such as "The score goes back to 0 after every catch."
  2. The timer counts up and the game never ends. Which block has the bug? What should it say?
  3. The apple keeps jumping back to the top and never falls. Which fix works?
  4. Sam fixed a bug, then said "Done!" without playing the game again. Why is it important to test again after a fix?

The answers are on the answers sheet, for grown-ups.

National curriculum in England

This worksheet practises these statements from the Years 3–6 computing programme of study:

  • Design, write and debug programs that accomplish specific goals, including controlling or simulating physical systems; solve problems by decomposing them into smaller parts
  • Use logical reasoning to explain how some simple algorithms work and to detect and correct errors in algorithms and programs

Source: National curriculum in England: computing programmes of study (DfE)

In the classroom

  • Run Face bug hunt in pairs, swapping instructions with a planted bug.
  • Use Practise A as a card sort: groups match bug cards to cause cards and explain their reasoning.

Questions and answers

What is debugging?

Debugging means finding and fixing mistakes, called bugs, in a program. Children test the program, describe what goes wrong, find the block causing it, fix it and test again.

Why should you only change one thing at a time when debugging?

Changing one thing at a time shows whether that change fixed the bug. If several things change at once, it is hard to know which one helped or caused a new problem.

More worksheets from Make Your Own Game: Code a Catching Game with Hazel

More Year 3 technology worksheets

One for every chapter of every game, with answers.

Browse them →