× Lesson 1 Lesson 2 Lesson 3 Lesson 4 Lesson 5 Lesson 6 Lesson 7 Lesson 8 Lesson 9 Lesson 10 Lesson 11 Lesson 12 Lesson 13 Lesson 14 Lesson 15 Lesson 16 Lesson 17 Lesson 18 Lesson 19 Lesson 20 Lesson 21 Lesson 22 Lesson 23 Lesson 24 Lesson 25 Mini Lesson 1 Mini Lesson 2 Mini Lesson 3 Mini Lesson 4 Mini Lesson 5


Lesson 3 - Variables

One of the key concepts of all languages, not just Python, are variables. Variables are basically a value with a name set by you. The basic syntax, aka the proper "grammar" of programming, of it is like so:

(name of variable) = (some form of data, such as numbers)

Without the parenthesises.

Try setting the word "number," without quotations, equal to any number that you would like

After you have set the your variable to what you want, output it by running:


Another cool thing about variables is that you can change the value of a variable, try this out by setting the number variable to a different number and once again run: