Worked example · Health and Well-being · Year 5

Debugging a healthy morning routine

DCF: Data and computational thinking → Problem-solving and modelling

Also assessed, LNF: Numeracy → Learning about geometry helps us understand shape, space and position, and learning about measurement helps us quantify in the real world → Measurement

What this is

A secure Year 5 response, annotated so you can see which success criterion each part meets. It is also the answer key. Key figures: the debugged routine takes 79 minutes (1 hour 19 minutes); Cai reaches the stop at 08:19, 9 minutes late; Plan A videos last at most 16 minutes; Plan B alarm at 06:46. The order of breakfast and teeth, or books and water bottle, can vary as long as the times are worked out correctly.

Step 1: predict

I think he will miss the bus because he watches videos for 30 minutes and everything else takes time too. It is over an hour of jobs and he only has 70 minutes.

A sensible prediction with a reason, made before calculating. Evidences criterion 1.

Step 2: find the bugs

StepWhat is wrong?How to fix it
2He puts his shoes on before he gets dressed and puts his socks on.Move “Put on shoes and coat” to after packing his bag, just before he walks to the stop.
72 seconds is far too short to clean your teeth.Brush teeth for about 2 minutes, like the NHS says.
8He walks to the bus stop before he packs his bag and fills his bottle, so he would leave them behind.Move “Walk to the bus stop” to the last step before END.
9The same instruction is written 4 times.Use a loop: Repeat 4 times: put a book in the bag.

Finds all 4 bugs, explains what would go wrong and gives a precise fix. Evidences criterion 2.

Step 3: the debugged algorithm

1. START: the alarm rings at 07:00. Get out of bed. 2. Go to the toilet, then wash hands and face. 3. Get dressed in school uniform and socks. 4. Watch videos on the tablet for 30 minutes. 5. Eat breakfast. 6. Brush teeth for 2 minutes. 7. Repeat 4 times: put a book in the bag. 8. Fill water bottle. 9. Put on shoes and coat. 10. Walk to the bus stop. 11. END.

Every bug is fixed, the order makes sense, and the loop replaces 4 lines with 1. Evidences criteria 2 and 3.

Step 4: the timetable

JobMinutesStartFinish
Toilet, then wash hands and face507:0007:05
Get dressed1007:0507:15
Watch videos3007:1507:45
Eat breakfast1507:4508:00
Brush teeth208:0008:02
Repeat 4 times: book in bag408:0208:06
Fill water bottle208:0608:08
Shoes and coat408:0808:12
Walk to the bus stop708:1208:19

(a) 5 + 10 + 30 + 15 + 2 + 4 + 2 + 4 + 7 = 79 minutes. 79 = 60 + 19, so 1 hour 19 minutes. Check: 07:00 + 1 hour 19 minutes = 08:19, which matches the last finish time.

(b) He reaches the stop at 08:19. The bus left at 08:10, so he misses it by 9 minutes. My prediction was right.

Each start time is the finish time before it, the loop is counted as 4 minutes, and the total is checked two ways. Evidences criterion 4.

Step 5: change the algorithm

(a) Plan A: 07:00 to 08:05 is 65 minutes. Without videos the jobs take 79 − 30 = 49 minutes. 65 − 49 = 16 minutes of videos at most. Step 4 becomes “Watch videos on the tablet for 16 minutes.”

(b) Plan B: the routine takes 79 minutes. 08:05 back 1 hour is 07:05, back 19 more minutes is 06:46. The alarm should ring at 06:46.

(c) Take the videos out of the morning and watch them after school instead. Cai would reach the stop at 07:49, with time to eat breakfast slowly, so he is not hungry or rushing. Waking up at 06:46 would mean less sleep, so Plan A or this change is better for his well-being.

Uses the total from Step 4 to work backwards, changes one instruction at a time to get the outcome Cai wants, and thinks about well-being as well as time. Evidences criteria 4 and 5.

If you finish early: answers

IF it is Tuesday, THEN put PE kit in the bag. About 2 or 3 minutes, so Plan A videos would need to be shorter again.

For example: snack and homework 15:40 to 16:20, videos 16:20 to 16:50, play outside 16:50 to 17:30.

Why this response is secure