Ack, just ran it from shell, realized my editor was just choking on a "maximum recursion depth exceeded" RuntimeError. Didn't realize generators used the call stack...
- Andrey On Fri, Feb 19, 2010 at 2:47 PM, Andrey Fedorov <anfedo...@gmail.com> wrote: > I implemented a Sieve of > Eratosthenes<http://en.wikipedia.org/wiki/Sieve_of_Eratosthenes>primes > algorithm using generators: > > http://gist.github.com/309109 > > > This code which chains together 500 generators works fine (~1/20th of a > second) on my laptop. The code which chaines 501 generators (s/498/499/ on > line 23) doesn't seem to finish. > > Does anyone know the reason for this, or can anyone point me where to look > for a good explanation? > > Cheers, > Andrey >
-- http://mail.python.org/mailman/listinfo/python-list