Trying to write a function that will print all numbers from 1 to 1000 that the sum of their figures is divisible by 8 : So just like the topic says, I'm trying to write an efficient function that will print all numbers from 1 to 1000 that the sum of their figures is divisible by 10.
I'm using this 'for': `for (var i = 1; i <= 1000; i++) {`
but not sure about the mathematics.
Thanks for the kind help.