Selection to control the flow in a program
I can explain that selection can control the flow of a program.
Selection to control the flow in a program
I can explain that selection can control the flow of a program.
These resources will be removed by end of Summer Term 2025.
Switch to our new teaching resources now - designed by teachers and leading subject experts, and tested in classrooms.
These resources were created for remote use during the pandemic and are not designed for classroom teaching.
Lesson details
Key learning points
- Conditions are events that can only be evaluated as True/False or yes/no.
- Selection in the form of if/then/else statements can be used to check conditions.
- Selection uses conditions to determine program flow.
Keywords
Flow - the order in which commands run in a program
Condition - a statement that can be either True or False
Selection - part of a program where if a condition is met then a set of commands are run
Common misconception
All parts of an if/then/else statement run every time.
Only the part that matches the condition will run.
To help you plan your year 6 computing lesson on: Selection to control the flow in a program, download all teaching resources for free and adapt to suit your pupils' needs...
To help you plan your year 6 computing lesson on: Selection to control the flow in a program, download all teaching resources for free and adapt to suit your pupils' needs.
The starter quiz will activate and check your pupils' prior knowledge, with versions available both with and without answers in PDF format.
We use learning cycles to break down learning into key concepts or ideas linked to the learning outcome. Each learning cycle features explanations with checks for understanding and practice tasks with feedback. All of this is found in our slide decks, ready for you to download and edit. The practice tasks are also available as printable worksheets and some lessons have additional materials with extra material you might need for teaching the lesson.
The assessment exit quiz will test your pupils' understanding of the key learning points.
Our video is a tool for planning, showing how other teachers might teach the lesson, offering helpful tips, modelled explanations and inspiration for your own delivery in the classroom. Plus, you can set it as homework or revision for pupils and keep their learning on track by sharing an online pupil version of this lesson.
Explore more key stage 2 computing lessons from the Sensing movement with physical computing unit, dive into the full primary computing curriculum, or learn more about lesson planning.
Equipment
Pupils will need access to a device with block-based programming software that can be used to program a physcial controller. Examples in this lesson use Microsoft MakeCode https://oak.link/makecode
Licence
Prior knowledge starter quiz
6 Questions
Q1.What is a benefit of using an emulator when developing a program?
Q2.What does it mean to transfer a program?
Q3.Put these steps in order for creating and running a program on a micro:bit:
Q4.Which describes a micro:bit best?
Q5.Match each term to its description:
a small programmable computer
a virtual tool for testing code
moving a program to a new device
Q6.What happens after you transfer a program to a controllable device?
Assessment exit quiz
6 Questions
Q1.What is a condition in programming?
Q2.Which part of a program decides which instructions run based on a condition?
Q3.What does the “if” part of an if/then/else statement do?
Q4.Match each example to the programming concept:
deciding if it is raining before going outside
the steps followed in a recipe
a statement like “temperature > 20”