pythonreference.com
search statements, functions, methods, exceptions*
hide categories'for' with a file | iterate over each string line in a file |
file .close() | close a file |
file .read() | read whole file as a single string |
file .readlines() | read a file as a list of strings |
file .write() | write to or append to a file |