Turning a flowchart into Python
A flowchart diamond (a decision) becomes if, or while when an arrow loops back to it. Rectangles become statements and parallelograms become input() or print().
Understanding Turning a flowchart into Python in Years 7–8 Creating Digital Solutions
What it does: Parallelograms show input or output. An input parallelogram is coded with input() and stored in a variable. Rectangles are process steps, so each one becomes a normal Python statement such as an assignment. A diamond with Yes and No paths that move forward is a one-off decision, so it becomes an if statement. An arrow looping back to the diamond means the check is repeated, so we use while. A parallelogram for input becomes input(). The second option just stores text and never asks the user anything. A decision with no loop back is coded as if x > 10:. Using while would repeat the print and could run forever.
Common mistakes: The decision diamond becomes an if statement, and every if line must end with a colon. It should be: if age >= 13:. The rectangle that adds 1 must be a statement that stores the answer. 'count + 1' works it out but does not save it, so count never changes and the loop never ends. It should be: count = count + 1.
Free printable worksheet with full answer key — or add this module to a class and your students practise it interactively.
This module's key terms are also in a printable crossword (Modules 50–125) and word search (Modules 3–125).
Take this worksheet further — free with Cloodit
Each concept is reinforced from every angle — learned, then applied, then tested.
Cloodit turns curriculum-aligned coding content into journeys students work through one biome at a time.
Over 100 of them, across seven natural biomes.
Turns their work into revision material ready for Flash Cards and Exam study.
Live, competitive practice for the start of the lesson or a teacher-led lesson finisher.
Honour your top performers, or encourage a student who's trying hard — ready to print in seconds.
Quick Questions
Match the Pairs
Key Term
if / whileFill in the Blanks
Spot the Error
Student with a class code? Join your class →