What Are Variables in Coding?
Why Do We Use Variables?
Store Information: Variables help us remember things while we code. Change Values: We can update what’s inside the variable whenever we need. Organize Data: Using variables makes our code neat and easy to read.
Types of Variables
Numbers: These are variables that store numerical values. For example, .age = 10 Text: These variables hold words or sentences. For example, .name = "Alice" Boolean: This type can only be true or false. For example, .isHappy = true
How to Create a Variable
Choose a name for your variable (like ).favoriteColor Decide what value you want to store (like ).favoriteColor = "blue" Now you can use favoriteColor in your code whenever you need to!
Fun Activity: Create Your Own Variables!
Your favorite food Your best friend’s name A fun number (like your age or how many pets you have)


