So, my 4th grader got this homework assignment:
Use the clues to find the mystery 5-digit number
- All the digits are different
- The Thousands digit is 7 more than the Tens digit
- The Hundreds digit is the sum of the Thousands digit and the Ones digit
- The total of the digits added together is 24
I'm a reasonably educated fully grown man but I could not figure out a way to solve this problem, aside from brute forcing thousands of combinations.
But, I know how to code so that's what I did.
Here is the solution