Make the code a bit more python.