GRADE 4 · COMPUTING · UNIT 1 · LESSON 1.8
Computational thinking and programming
Debug indefinite-loop puzzles
Trace a bounce and a clone-position test.
LET’S LOOK, THINK AND TRY
Debug indefinite-loop puzzles
Trace a bounce and a clone-position test.
- trace a bounce and a clone-position test
- explain a correction using the target outcome

Explore the clues
Tap one card to find out more.
Notice the idea
An indefinite loop keeps repeating until something outside it stops the program. Instructions before the loop happen first; only the instructions inside it repeat.
Work through an example
A greeting before FOREVER { change costume; wait } happens once. Each later cycle changes costume and waits. A trace of a few cycles is a sample, not the end of forever.
Talk and check
Separate startup from the loop body. When a task supplies positions, directions or random choices, use those exact test values.

Think it through with Paxa!
Use fictional examples and the supplied model. Ask a grown-up before using equipment or exploring an online service.
A paper prediction explains a model. A real program or device also needs supervised practical testing.
Our Unit 1 learning path
- Lesson 1.1: Discover instructions and loops
- Lesson 1.2: Trace and correct a route
- Lesson 1.3: Build a concise paper program
- Lesson 1.4: Apply, debug and review
- Lesson 1.5: Explore forever blocks
- Lesson 1.6: Predict outputs and solve number puzzles
- Lesson 1.7: Build a paper Scratch animation
- Lesson 1.8: Debug indefinite-loop puzzles
- Lesson 1.9: Explore count-controlled loops
- Lesson 1.10: Debug maze and nested-loop puzzles
- Lesson 1.11: Draw shapes with counted repeats
- Lesson 1.12: Solve count-controlled coding challenges
- Lesson 1.13: Discover input, processing and output
- Lesson 1.14: Plan programs using user inputs
- Lesson 1.15: Build and test input-controlled programs
- Lesson 1.16: Debug input-and-output challenges
- Lesson 1.17: Break a problem into smaller parts
- Lesson 1.18: Trace routines and their triggers
- Lesson 1.19: Build a program with shared routines
- Lesson 1.20: Debug and test decomposed programs
- Lesson 1.21: Use helpful code comments
- Lesson 1.22: Plan and record fair program tests
- Lesson 1.23: Debug counted drawing programs
- Lesson 1.24: Review, test and explain a solution
- Lesson 1.25: Explore a physical computing device
- Lesson 1.26: Use buttons to control LED output
- Lesson 1.27: Build a digital-pet algorithm
- Lesson 1.28: Debug physical-device programs
- Lesson 1.29: Build and test Paxa explorer
For grown-ups: using this lesson
Discuss the idea, let your child make a prediction, then check the evidence together. Drawings, explanations and practical skills need human feedback alongside the automatic score.
Choose “Mark lesson complete” when ready. Optional account progress saves lesson position and completion; save personal workbook responses before leaving.
2. Fill in your workbook
Read the instructions and use each worksheet’s own code, diagrams, tables and key. Choose answers, write or draw. Use Answer list for larger controls.
Opening your PDF…
Swipe sideways across the worksheet on a small screen, or use “Answer list” for larger controls.
You’ve completed the checked activities.
TAKE YOUR PRACTICE OFFLINE
3. Download the student worksheet
All 6 original A4 student pages, ready for pencil-and-paper practice. Choose Review Answers to check your work on this webpage.
Student worksheet only · PDF · 8.6 MiB · No answer key included
TRY FIRST, THEN CHECK TOGETHER
Download the student worksheet →4. Answers & guidance
Finished your try? Open the guide and compare one worksheet at a time. Your own words may be different and still explain the right idea.
Shown on this webpage only. There is no answer-key download, and this guide is left out when printing the page.
Show answers for all 6 worksheets
Worksheet 1
- Question 1: Write the position after the first move.
40 - Question 2: Which direction follows the first bounce?
left - Question 3: Write the position after the third move.
20
Worksheet 2
- Question 4: Which edit best meets the target?
Move the greeting before forever. - Question 5: After that edit, how often does Hello appear per flag click?
once - Question 6: Which blocks must remain inside forever?
move and edge bounce
Worksheet 3
- Question 7: Where does A create its first clone?
C3 / c3 - Question 8: Where does B create its first clone?
A1 / a1 - Question 9: Which conclusion is supported?
The first copy position can depend on block order.
Worksheet 4
- Question 10: An animation must keep repeating but runs its actions only once.
A / a - Question 11: Hello repeats each cycle but should be said once.
B / b - Question 12: A clone appears at the old position, but the target is the new position.
C / c - Question 13: The pauses are too short for pupils to follow.
D / d
Worksheet 5
- Question 14: Which missing final destination fixes the tour?
School - Question 15: Why is the return leg needed?
Each tour must start and finish at the same place.
Worksheet 6
- Question 16: Write a complete block plan for this target.
when green flag clicked; say Ready once; forever { go to next random test cell; create clone of myself; wait1 second }. Accept equivalent clear arrangement; greeting outside loop and copying after each move. - Question 17: State both first copy locations in order and explain one check you made.
B3 then C2. Check that move precedes clone and that both actions repeat; earlier copies stay in place. Accept another precise check linked to the target.
Curriculum & workbook reference
- Cambridge Primary Computing Learner’s Book 4 — pages 21–36
- PaxaKids Grade 4 Computing Lesson 1.8: Debug indefinite-loop puzzles — pages 1–6
Computing for your homeschool day
Explore Indefinite loops with this free Grade 4 Computing lesson. Read one idea together, try the fillable workbook and return to review at your own pace. Download the same student worksheet PDF for pencil-and-paper practice.
Fit learning around your family’s day. There is no timer and no sign-up is needed to use the lesson. An optional account saves your lesson position and completion across devices. Workbook responses and drawings stay in this tab; save a copy of your responses before leaving.
Understand your results
Your answers are checked in your browser. Open responses need grown-up review and are shown separately from the automatic score. Check your work, then use “Retry answers to practise” to revisit mistakes while keeping correct responses.
Choose Review Answers after trying the activity. The guide stays on the webpage; the worksheet download contains only the student pages.
The book pages identify the related topic. The teaching, diagrams and worksheet activities are original PaxaKids learning materials. For curriculum background, visit the Cambridge Primary Computing overview.
