Here is my celebration post for entering level 3 in Project Euler.
Again I left in my debug prints. I am in process of adapting myself to new .format style of formatting. I have commented out the prints though to get visible the running time of the functions own action. It is not doing half bad actually:
J:\test\Project Euler>\python27\python -m timeit "import euler61" "euler61.euler61()"
100 loops, best of 3: 2.5 msec per loop
That is faster than the printing of the result to console with newline.
Of course, my generator expression is anything but PEP8 compliant in it's simplicity, but it is self documenting for me.
Problem description can be found in: http://projecteuler.net/index.php?section=problems&id=61
Edited 4 Years Ago by pyTony: Spelling