Skip to content

Chapter 2

Jarlin Almanzar edited this page Oct 22, 2019 · 16 revisions

Naming and Using Variables

Contain

  • Only letters
  • Only numbers
  • Only underscores
  • Can start with an underscore or letters, not numbers

Can't Contain

  • spaces
  • keywords
  • function names

Variables and Simple Data Types

Variables are labels for values variable_name = variable_value

Data Types

Strings

A series of characters

Anything inside "this" or 'this' is considered a string

"" allow for for quotes and apostrophes , while '' does not

Variable String Example

#variable
message = "Hello World"
print(message)

Clone this wiki locally