122 Control structures
Learn to design and implement sequence, selection and repetition using pseudocode, flowcharts and Python.
This module introduces the three essential control structures used in all programming: sequence, selection, and repetition. Students will learn to interpret and apply these structures in pseudocode, flowcharts, and Python code, using computational thinking to develop correct and efficient algorithms. The module emphasises the translation of design into code, including desk checking and the use of visual modelling tools to support logical clarity.
Targets
In this topic, students learn to:
Recognise and apply the three fundamental control structures: sequence, selection, and repetition
Design clear and logical algorithms using pseudocode and flowcharts
Translate control structure algorithms into correct and idiomatic Python code
Distinguish between pre-test, post-test and counted loops and select appropriately
Identify when to apply binary and multi-way selection in solving problems
Combine and nest control structures to handle more complex logic
Use desk checking and test data to verify the correctness of an algorithm
Glossary
sequence
A control structure where steps are executed in order, one after another.
selection
A control structure that chooses between two or more paths based on a condition.
binary selection
A two-way decision structure, typically implemented with an if/else block.
multi-way selection
A selection structure that handles multiple possible conditions (e.g. if/elif/else).
nested IF
An if structure inside another if, used to test multiple related conditions.
repetition
A control structure that repeats a block of code while a condition is true or for a specific number of times.
pre-test loop
A loop that checks the condition before executing the body (e.g. while).
post-test loop
A loop that executes at least once and checks the condition after (e.g. repeat-until).
counted loop
A loop that repeats a fixed number of times, often using a counter (e.g. for).
flowchart
A diagram that represents the flow of an algorithm using standard symbols.
pseudocode
A structured description of an algorithm using programming-like notation without specific syntax.
desk checking
A process of manually tracing through an algorithm or program with test data.
Overview
Control structures form the foundation of all algorithm design. In this module, you’ll explore how software behaves by following instructions in a specific order, making data-based decisions, and repeating tasks as needed. You’ll practise writing algorithms using pseudocode and flowcharts and implement them using Python. Through hands-on activities, you’ll build confidence in designing and debugging programs that use sequence, selection and repetition.
You’ll also learn how to combine these structures to solve real-world problems, applying computational thinking techniques such as abstraction and decomposition. This understanding will help you build well-structured code that is easy to read, maintain and extend—skills essential to all future programming work.
Last updated
Was this helpful?