Bugsy
Explains
3 hearts left

Variables

New idea

How does a game remember your score?

You collect a coin and the score jumps from 40 to 50. A second later it is still 50. Something in the program is remembering that number.

That something is a variable, a labelled box in the computer's memory. The label is its name, like score, and inside the box sits one value.

We'll write code in a tiny, Python-like style. score = 5 means: put 5 into the box labelled score. The = is not "equals", it is an arrow that says store this. And print(score) shows what is inside the box on the screen.