Intro to Python
AriTelford1 (0)

Introduction

Python is an easy language to learn with super easy syntax. Here's a basic program
print('Hello world')
This program is pretty self explanatory, but there's one important thing. Notice the single quotes. You can use double quotes or single quotes, but you won't be able to use them again. By that I mean you can't say
print("John said "Hello world" to the man")
because the python interpreter will go to the next quote and end there, thus creating an error. The same goes for single quotes.

Variables

Variables are very easy in python. First, write the name of it, then an equals sign, and the value. For example, you could say
variable = 'value'
To print this new variable, just use the print command we learned about
print(variable)
this will output value to the console.

That's all for now. I'll post another tutorial soon.

You are viewing a single comment. View All
AriTelford1 (0)

@AllAwesome497 I did not know that, thanks for sharing!