Problem 29 is quite easy in Python.