Learn to Code
John F. Dumas
contact me | resume | how it works | example programs | testimonials | main page
C++ - Primes
► Problem Description: Write a c++ program that can output all the prime numbers up to a given value of 'N' without using loops, division or the modulus operator.
► Example Output:
Here's a list of the first 15 primes. The program that generated this list used recursion and the sieve of eratosthenes to produce its results within the stated restrictions.
► Source code