You are viewing a single comment's thread. Return to all comments →
Clever, took me a minute to understand what you did. More efficient than re-adding each series of ints in embedded loops.
Quick Summary of what was done:
1) The first loops adds the first m ints together to see if they equal d.
2) The second loop removes the first digit from the last calculation, and adds a later one to replace it.