TalentJR

Lesson 2

Variables & Basic Data Types

Learn to store and manipulate data using variables

1What is a Variable?✨

A variable is a labeled container that stores information. Think of it as a box with a name on it.

2Creating Variables🎯

💻 code
name = "Alice"
age = 10
height = 4.8

3Data Types in Python💡

💻 code
1. Strings (Text)
   message = "Hello"
💻 code
2. Integers (Whole numbers)
   count = 42
💻 code
3. Floats (Decimal numbers)
   price = 19.99
💻 code
4. Booleans (True/False)
   is_student = True

4Variable Naming Rules🚀

  • ✓ Use descriptive names: student_name, test_score
  • ✓ Use lowercase with underscores
  • ✗ Don't use spaces or special characters
  • ✗ Don't start with numbers

5Real Example🔍

💻 code
student_name = "Jordan"
student_age = 11
gpa = 3.8
is_honor_student = True

🎯 Practice Challenges

Master Variables & Basic Data Types by completing all 3 difficulty levels

🟢 EASY

Variables & Basic Data Types - Easy Challenge

Start with the basics. Perfect for beginners!

🟡 MEDIUM

Variables & Basic Data Types - Medium Challenge

Get more challenging. Build your confidence!

🔴 HARD

Variables & Basic Data Types - Hard Challenge

Master this concept. Prove your skills!

🏆 Study a lesson for 2+ minutes to earn +10 TalentJR Points a day. Badges, certificates & prizes →

Ready to Master Variables & Basic Data Types? 🚀

Complete the challenges, take the quiz and keep your learning streak going!