What are Booleans?
A Boolean is a type of data that has only two possible values: true or false. You can think of a Boolean like the answer to a yes or no question:
Yes = true, No = false.
For example: Is it your birthday today?
If yes, the Boolean is true.
If no, the Boolean is false.
Even though the question stays the same, the Boolean value can change depending on the situation. This kind of true/false thinking helps students write code that responds to what’s happening in the moment.
Booleans in Kodable Basics
Students first explore Booleans in the Asteroid Belt course. In these levels, a tunnel blocks the fuzz’s path—and students must use Boolean logic to open it. These early activities help students understand how a single true/false value can change the outcome of a program.
To solve the maze, they will:
Check if the tunnel door is open or closed
Look at the Boolean condition shown above the tunnel
Use buttons to change the value from false to true
Example:
A statement like door.open == FALSE means the door is closed. If the fuzz rolls over the correct button, the value changes to TRUE—opening the tunnel and letting the fuzz continue through the maze.
Booleans in Kodable Creator
Students continue working with Booleans in the Creator course, Key Quest. In this game, they use conditionals that check for true or false to change how objects behave.By using Booleans inside functions, students can program smart reactions that make their games feel more interactive and dynamic.
Example:
In the screenshot below, the Anchor object uses a Boolean called HasKey. The code checks:
If HasKey is true → the anchor moves quickly
If HasKey is false → the anchor moves slowly
Why It Matters
Booleans teach students:
How to check conditions and react with code
The basics of true/false logic
How to make code that adapts to different situations
Booleans are a simple but essential part of programming—and they open the door to more complex logic later on.