I need an idea for an algorithm which will find prime numbers from a given array(sieve of Arothestenes is too slow,I`m thinking about sieve of Atkin,but I can`t find any examples,so...if any idea I`ll be grateful:-)
Printable View
I need an idea for an algorithm which will find prime numbers from a given array(sieve of Arothestenes is too slow,I`m thinking about sieve of Atkin,but I can`t find any examples,so...if any idea I`ll be grateful:-)
Welcome to the forums!
That was one of the contests, to find all primes less than 10000. You can find source code to all the entries.
http://www.vbforums.com/forumdisplay.php?f=67
Thanks but I`ve got an array from 1 to 1 000 000 000 then I`ve got x,y which x-y<=100000 and x<=y<= 1000 000 000and I`ve got to find prime numbers which are in array made by x,y
This might be a little out of your league, but research the quadritic sieve.