def prime_sieve(limit): prime = [True] * limit prime = prime = False for i, is_prime in enumerate(prime): if is_prime: yield i for n in range(i * i, limit, i): prime[n] = False
Member for 3 years, 5 months
0 profile views
Last seen Jul 13 '18 at 13:21
- Code Review 39k 39k 66 gold badges5858 silver badges120120 bronze badges
- Stack Overflow 6k 6k 2424 silver badges4141 bronze badges
- Ask Ubuntu 946 946 99 silver badges1414 bronze badges
- Physics 620 620 55 silver badges1010 bronze badges
- Science Fiction & Fantasy 413 413 33 silver badges1010 bronze badges
- View network profile
Top network posts
- 56 Why is a `for` loop so much faster to count True values?
- 53 String reversal in Python
- 49 Send a tweet to ISP when internet speed drops
- 26 Powerful GUI Calculator for Linux?
- 25 Comma Code (project from "Automate the Boring Stuff with Python")
- 22 Large Number Limit Extravaganza
- 22 What is the name of this plot that has rows with two connected dots?
- View more network posts →
Keeping a low profile.
This user hasn't posted yet.
Jul 26 '19