Sift the Two's and Sift the Three's
The Sieve of Eratosthenes.
When the multiples sublime,
The numbers the remain are Prime
Run: ./Sieve [number] [output_file]
number as the max value of the primes generated
output as the output filename
Format type :
./Sieve "min=x max=y amoutn=z output=a"
Where:
-
min Minimum prime value
-
max Maximum prime value
-
amount Maximum amount of primes generated
-
output output filename (If the filename is a number, write to corresponding file descriptor)
Implement Eratosthenes (inc & segmented)
Sieve of Atkins to look into for more uwu
Disclaimer: This is actually Euler's Sieve, not Erathostene's >.> hehe gottem