Variables are just labeled boxes!
We’ll fill the boxes, use them in math, and even save results to storage.
All photos are now cropped files with no visible text.
What is a Variable?
Variables live in RAM (working memory)
score
number
studentName
text
isReady
true/false
10
Alex
true
Press Play to store values into the variable boxes in RAM.
Watch 10 → score, Alex → studentName, true → isReady.
Why use variables?
They help computers remember and reuse information while working.
Score changes:
score goes up when you do well.
Name tags:
studentName holds words like “Alex”.
Switches:
isReady is true/false like a light switch.Change the values
Hit Play to see your new values slide into the RAM boxes.
Common Variable Types (Kid-Friendly)
Number
Holds numbers like 7 or 12.5. We can use numbers in math.
Text
Holds words and letters like “Alex” or “Blue”. Computers store letters as codes.
True/False
Holds yes-or-no values: true or false. Example: isReady = true.
Using Variables in an Operation
Enter two numbers for variables num1 and num2. We will convert them to binary, store them in RAM, send them to the CPU for the chosen operation, put the result back into result, and then let you Save to Storage.
Input
RAM (num1, num2, result)
Storage
CPU
Game: Initialize the Variables
Drag each value to the variable with the matching type.
scorenumber
studentNametext
isReadytrue/false
levelnumber
favoriteColortext
hasKeytrue/false
Initialized: 0 / 6
7
12
Alex
Blue
true
false