One of the basic building blocks of programming. A variable holds a value, such as True
or False
, which can change over the course of the program. It has a name which allows you to access that value during program execution.
In Python, variables should generally have names in snake_case
. The following additional rules on variable names are enforced:
- Variable names cannot begin with an underscore (these names are reserved for Ren’Py)
- Variable names cannot begin with a number (e.g.
two_cookies
is fine but2cookies
or2_cookies
is not) - Variables may only contain alphanumeric characters and underscores. Characters like hyphens and spaces are not allowed.