On Sat, 11 Feb 2006 13:33:58 +0000, Ian Bygrave wrote: > Well, given a hypothetical new function 'sieve'
which should have been: def sieve(f,l): if not l: return l head,tail=l[0],l[1:] def filter_func(x): return f(x,head) tail=filter(filter_func,tail) return [head]+sieve(f,tail) > The prime generation can be reduced to: > > from operator import * > sieve(mod,range(2,99)) --Ian Bygrave -- http://mail.python.org/mailman/listinfo/python-list