🤖
KidsCode
  • Welcome to KidsCode
  • Setting up mBlock
  • Arduino Lessons
    • Arduino Beginner Lessons
      • Blinking an LED
      • LED Switching
      • LED Chasing
      • Traffic Signal
      • Buzzer
      • Buzzer + Push Button
      • LED + Push Button
    • Bluetooth LED
  • Arduino Robot Car
    • Arduino Bluetooth Car
      • What you will need
      • Circuit Diagram
      • Assembly the Car
      • Upload the Code
      • Bluetooth setup and Test
  • Micro:bit Beginners
    • micro:bit, the hardware
    • Overview of MakeCode
    • Video Library
    • Lesson 1
      • My micro:bit
      • Safety first!
      • Plug in your micro:bit
      • My name is?
      • Learning Outcomes
    • Lesson 2
      • Whats your name again?
      • How fast is your heart beat?
    • Lesson 3
      • Please switch on the TV
      • One, Two, Three
      • Keep pressing that buttons
    • Lesson 4
      • Variable, what is that!!
      • Step Counter
      • 1 + 1 = 2
  • Micro:bit Advanced Activities
    • Blinking an LED
    • Traffic Signal
Powered by GitBook
On this page

Was this helpful?

  1. Micro:bit Beginners
  2. Lesson 4

Variable, what is that!!

In the lesson you will explain to the kids what a variable is.

Teachers Notes

In this lesson, you will need to explain what is a variable with a simple example of keeping score in a game.

You will need a cup and 5 pieces of paper that will fit in the cup. Number each piece of paper from 1 to 5. You will also need a ball to play a game. You can play a quick game of soccer with the kids where you or one kid will kick the ball through the goal posts (you can make this with two chairs)

Explanation to the Kids:

Think of the cup as a variable. At first, the cup is always empty. This means it is zero. We will call this cup (or variable) score. This variable will keep track of how many goals is scored.

Now start to play your game. Kick the ball through the goals once.

Then add the number one piece of paper into the cup. Now explain to the kids that you have added a value of 1 to the variable.

Kick the ball through the goals again.

Then remove the paper 1 and add paper 2 to the cup. Now the score is 2.

Repeat this 5 times until you add the paper 5 to the cup.

Now explain to the kids that each time you scored a goal you added 1 to the variable or changed the variable value by 1. Each time you wanted to see what the score was, you check with the value of the variable was and that gave you the score.

Repeat the concept if the kids dont get it first time.

PreviousLesson 4NextStep Counter

Last updated 5 years ago

Was this helpful?