|
Thirdly, (and this one's common sense), you only need to test half the numbers up to the value of the tested number. I.e, you know that x will not be cleanly divisible by a number that's greater than x/2, apart from x.
did that in my previous program, that must be why this one is 4 seconds slower on the 100000 -.- :p
this one takes about 7 seconds, my previous one did it in 3,5 but deleted it
thanks for pointing that out
im also working on the one w/ only odd numbers
cya
|