My solution of the python challenge (http://www.pythonchallenge.com/)