2 ms·
Now let's imagine you want the first 65,000 primes so you can initialize a primality testing algorithm for RSA or something. You'll want much better performance
by minopret 13y ago
Now let's imagine you want the first 65,000 primes so you can initialize a primality testing algorithm for RSA or something. You'll want much better performance. And you can get it without too much trouble.
In short, my implementation in my Stack Overflow question that follows, using a parameter as counter variable, is not too hard to develop and is much faster.
http://stackoverflow.com/questions/16271592 http://stackoverflow.com/questions/16271592
The question that I asked there is how to do the same using stream processing. It's not the first question of its kind there, but it's the one I have at hand. I asked because my search before I asked didn't turn up the others.