Use "with open" to make sure files are closed and handles are released in case of an error
Merge pull request #1 from Prinz23/use_with_open

Use "with open"