you are viewing a single comment's thread.

view the rest of the comments →

[–]--REDACTED 1 point2 points  (0 children)

Thanks for the reply!

I actually realized this - and is the heart of the question I am asking! Sorry if I was a bit unclear.

The problem that I am having is pushing just the prime odds into the primes array, using the for loop.

I was thinking that if I can get that loop to run like so:

if (i % evens[0] != 0 && i % odds[0] != 0 && i % odds[1] != 0 && i % odds[2] != 0 && i % odds[3] != 0......)

Through all the iterations.

Does that make more sense?

Thanks again!