Sep 26, 2013 at 7:03pm Sep 26, 2013 at 7:03pm UTC
Hi there,
A nifty little trick for this kind of thing is to use the modulus operator %.
It returns the remainder of the division between its left operand and its right operand.
Few examples:
2 % 2 = 0
3 % 2 = 1
6 % 4 = 2
20000 % 10000 = 0
So in your code you could test for this using:
if ( (i%10000) == 0 )
Hope that helps.
All the best,
NwN
Sep 26, 2013 at 7:07pm Sep 26, 2013 at 7:07pm UTC
Great answer, I was expecting the Modulus to come into play first as it's the most easiest. Great non the less.
Any other takers?
EDIT: Will mark this as solved at 20:30.
Last edited on Sep 26, 2013 at 7:09pm Sep 26, 2013 at 7:09pm UTC