Maze Game

IF this... THEN that... ELSE something else


Year 7 Computer Science — Conditionals & Flowcharts

Reading a Flowchart

Flowchart: "Is it raining?"

YES: Take umbrella → Leave the house

NO: Wear sunglasses → Leave the house


⬭ Oval
Start / End
▭ Rectangle
Action
◇ Diamond
Decision (Yes/No)

The Diamond Rule

Every diamond has exactly TWO exits:

◇ Is key = True?
├── YES → cross the bridge
└── NO → go back to start of row

A diamond = one IF/ELSE statement.

One question. Two possible paths.

Maze Rules

Trigger Card Example

You land on a square. The card reads:

TRAP SQUARE

IF key = True:
    skip trap safely
ELSE:
    health = health - 3

Write this as a diamond in your flowchart!

PLAY!


Navigate the maze. Flip trigger cards. Follow the rules.

Write IF/ELSE notation for each card on your flowchart worksheet.

Now Draw It

Convert your maze journey into a complete flowchart:

Discussion

Key Takeaway

IF/ELSE creates decision points.

The program asks a yes/no question and takes a different path depending on the answer.

Every diamond in a flowchart is one IF statement.
1 / 9