It will be almost twice as fast, using half as much space, if you only sieve over odd numbers.
Activity