A particularly interesting program
<p>we did this problem today in math class to kill time after a quiz, and i was wondering if i could make a program along these lines</p>

<p>so the idea is this:<br>
take the number 123,456,789<br>
the first digit from the left is divisible by 1, good, continue<br>
the first 2 digits from the left are divisible by 2, good, continue<br>
the first 3 digits from the left are divisible by 3, good, continue<br>
the first 4 digits from the left are NOT divisible by 4, you get a remainder, bad, restart with different numbers, or go back until one of the numbers can be replaced (the even spaces are pretty interchangeable)<br>
the tricky part here is that you cant use the same integer twice<br>
the only place we can be sure about is the fifth place, so we can tell that the number will look something like:  _ _ _, _ 5 _, _ _ _  </p>

<p>i want the program to print the number(s) which is(are) perfectly divisible, all the way to the ones place. im pretty sure that only one number fits this criteria, but id like to know if this is true, which is why im trying to make this program.  </p>

<p>what i need help with is how i should go about checking if each number divided by its place has no remainder, and how to go back if it doesnt fit.  </p>

<p>pretty new to coding..anything helps  </p>
