Cheatsheet Python

Cheatsheat for Python

Comment # This is a comment in a Python file
print print ("Hello World!")
Arguments call the script like myscript.py arg1 arg2 arg3

print sys.argv[1]
print sys.argv[2]
print sys.argv[3]
If
if (condition):
    # indented four spaces
    # Do stuff
else:
    # Do other stuff
For for x in range(6):
    # Do stuff
Exit sys.exit(0)
read cvs file in bash