user avatar
user avatar
user avatar
Graipher
  • Member for 7 years, 4 months
  • Last seen this week
Stats
640
reputation
27k
reached
6
answers
0
questions
Loading…
About
def prime_sieve(limit):
    prime = [True] * limit
    prime[0] = prime[1] = False

    for i, is_prime in enumerate(prime):
        if is_prime:
            yield i
            for n in range(i * i, limit, i):
                prime[n] = False

http://codereview.stackexchange.com/a/150447/98493

This user doesn’t have any gold badges yet.
5
silver badges
10
bronze badges
22
Score
4
Posts
67
Posts %
19
Score
1
Posts
17
Posts %
19
Score
1
Posts
17
Posts %
12
Score
1
Posts
17
Posts %
12
Score
1
Posts
17
Posts %
12
Score
1
Posts
17
Posts %