Ask coding questions

← Back to all posts
How should I implement the algorithm? C++
DeepGreen (8)

I want to write a program that generates prime numbers.

I want to write using the Sieve of Eratosthenes algorithm.

malvoliothegood (845)

If you do a search on the Net for 'Sieve of Eratosthenes to Generate Primes C++' you will find plenty of example code. Choose the algorithm that you understand the best.