๐ป Coding games ยท free, no sign-up
Code builder: put the lines in order.
Play Code Builder
Loading Code Builderโฆ
How to play Code Builder
- Choose a level and read the goal: what the program should print.
- Tap lines from the pile to build the program, top to bottom. Tap a placed line to take it back.
- Press Run. A program that prints the goal first time scores 30 points.
- If it fails, read what it printed and try a different order.
Tips and strategy
- A variable must be set before a line uses it: put the starting values first.
- A line ending in a colon (for, if, def, while) is followed by indented lines that belong to it.
- A function must be defined before you call it.
- Say the program aloud in order: set up, repeat or decide, then print the result.
Keep playing
More games you might like
FAQ
Code Builder: questions
What is a Parsons problem?
A puzzle where the lines of a correct program are given in a mixed-up order and you put them back. It practises how code flows without needing to type.
Does the order of lines matter in Python?
Yes. Python runs lines from top to bottom, so a variable must be set before it is used and a function must be defined before it is called.
Why are some lines indented?
Indented lines belong to the line above, such as the body of a for loop, an if statement or a function. In Python the indent is part of the code.
Do I need to know Python already?
A little helps, but the goal line tells you what the program should print, which is enough to work out the order.
Start a conversation
Questions about classes?
A parent or guardian can share the learner's age, level and goals, and we'll suggest a starting point and confirm the format before anything is booked.
- Tell us the learnerโs age or grade and goals
- Weโll suggest a suitable class or learning path
- Weโll confirm format, timing and fees with a parent or guardian