Commit Graph
6 Commits
Author SHA1 Message Date
deix 3fe4e1fd25 And another comparisons to singletons.. 2017-08-28 19:13:25 +02:00
deix 383d09ff29 Try to combine some if statements 2017-08-28 19:13:04 +02:00
deix 101332316a Another comparisons to singletons... 2017-08-28 18:37:12 +02:00
deix dbc0d995e3 The start parameter for enumerate()
Since python version 2.6 the start parameter was added and can be used
2017-08-28 18:14:09 +02:00
deix 00e5246f96 Comparisons to singletons like None should always be done with is or is not, never the equality operators. 2017-08-28 17:51:27 +02:00
deix d9330ef698 Use the "with" keyword when dealing with file objects
It is good practice to use the "with" keyword when dealing with file objects. This has the advantage that the file is properly closed after its suite finishes, even if an exception is raised on the way. It is also much shorter than writing equivalent try-finally blocks
2017-08-28 17:20:38 +02:00