On 7 April 2013 20:23, Ian Foote <i...@feete.org> wrote: > I'm surprised no one has suggested: > >>>> import math >>>> sum( x*x for x in range(1, int(math.sqrt(100)), 2))
Yeah! And I'm surprised no one came up with: >>> from itertools import count, takewhile >>> sum(takewhile((100).__gt__, filter((2).__rmod__, map((2).__rpow__, >>> count(1))))) 165 :) -- Arnaud -- http://mail.python.org/mailman/listinfo/python-list