Session 8

Learning targets

I can mix existing code

I can use a more systematic approach to debugging code, justifying what is wrong and how it can be corrected

A.L.E.X bugs


Ask children to have their whiteboards and pens or iPads ready. Mirror your iPad to the screen and work through the 'Play' levels on the A.L.E.X app, with children attempting to write down the algorithm first. Choose a selection of children to read out their commands. 'Bugs' will undoubtedly come up as you move through the levels. Draw a bug on the whiteboard and every time their is a 'chink' in the code, have the children call out 'splat that bug!'. Remind the children that solving problems in code, or removing bugs, is referred to as 'debugging'.

After several levels, challenge the children to come up with the algorithms without writing anything down - more chance for bugs to crop up! When this happens, and you need to 'Splat that bug!', ask the children to justify their reasoning and explain what the correct choice is.



Bugging me!


Share this link on Seesaw: https://studio.code.org/s/course2/stage/10/puzzle/1


Work through the first puzzle together. Once you have solved the problem, take a screenshot and place on a page in your coding digital book/journal. Use the voice recorder to leave an audio button next to the image where you explain what the 'bug' was and how you 'debugged' the code. Pay reference to how you used a more efficient choice too, including a loop which from previous learning we know speeds up a computer's performance.



Bug planting


Where time allows or if some pupils need a further challenge, have the children go back through previous levels, purposefully adding bugs to their solutions. They can then ask other pupils to debug their work.


If they need more practise: https://studio.code.org/s/course1/stage/5/puzzle/1