Exercise:04 Python variable and Its types

 

Variable Assignment

In Python, a variable allows you to refer to a value with a name. To create a variable use =, like this example:

x = 5

You can now use the name of this variable, x, instead of the actual value, 5.

Remember, = in Python means assignment, it doesn't test equality!


Instructions
100 XP
  • Create a variable savings with the value 100.
  • Check out this variable by typing print(savings) in the script.


Comments