Programming Concepts-Variables March 6, 2008
Posted by wagongrrl in General, Scratch.Tags: programming, Scratch, variables
1 comment so far
Variables are used in Scratch to store numeric information. You have learned about variables in Math, how they store or represent numbers that are unknown. A simple way to explain this is that variables store numbers that change over time. Think about a score in a game, or is your character has lives or strengths; these are numbers that change depending upon what else is happening in the program. Just like when you solve or balance an equation, if you change x, then y must change.
The example I showed in class was a simple race track with cars moving around and a variable that counted the number of times the car crossed the finish line (the number of laps).
Here are some race examples that students have created to demonstrate the concept.