This is a small collection of sieves.
  1. The first is in pure Python, and is #!'d to pypy3.
  2. The second is in CPython with numpy.
  3. The third is in Java.
  4. The fourth runs on micropython, a python implementation intended for embedded systems that also runs on Linux.
  5. The fifth is is in Rust, and is the fastest version - even faster than Java.
Like any prime number sieve, these will compute the primes beneath a particular number.

You can obtain them here.


Hits: 2854
Timestamp: 2024-12-27 07:38:24 PST

Back to Dan's tech tidbits

You can e-mail the author with questions or comments: