Brain Teasers
One to Nine
Arrange the digits from 1 to 9 to make a 9-digit number ABCDEFGHI which satisfies the following conditions:
1) AB is divisible by 2;
2) ABC is divisible by 3;
3) ABCD is divisible by 4;
4) ABCDE is divisible by 5;
5) ABCDEF is divisible by 6;
6) ABCDEFG is divisible by 7;
7) ABCDEFGH is divisible by 8;
8) ABCDEFGHI is divisible by 9.
There is only one solution.
1) AB is divisible by 2;
2) ABC is divisible by 3;
3) ABCD is divisible by 4;
4) ABCDE is divisible by 5;
5) ABCDEF is divisible by 6;
6) ABCDEFG is divisible by 7;
7) ABCDEFGH is divisible by 8;
8) ABCDEFGHI is divisible by 9.
There is only one solution.
Hint
Condition 8 is the easiest to satisfy just because it is automatically satisfied. But condition 6 is the hardest to satisfy, and should be left last.Answer
From condition 4, we know that E equals 5.From conditions 1, 3, 5 and 7, we know that B, D, F, H are even numbers, therefore A, C, G, I are 1, 3, 7, 9 in some order.
Furthermore, from conditions 3 and 7 we know that CD is divisible by 4 and GH is divisible by 8 (because FGH is divisible by 8 and F is even). Because C and G are odd, D and H must be 2 and 6 in some order.
From conditions 2 and 5, we know that A+B+C, D+E+F, G+H+I are all divisible by 3.
If D=2, then F=8, H=6, B=4. A+4+C is divisible by 3, therefore A and C must be 1 and 7 in some order, G and I must be 3 and 9 in some order. G6 is divisible by 8, therefore G=9. But neither 1472589 nor 7412589 is divisible by 7.
Therefore D=6, and F=4, H=2, B=8. G2 is divisible by 8, therefore G=3 or 7. A+8+C is divisible by 3, therefore one of A and C is chosen from 1 and 7, the other is chosen from 3 and 9.
If G=3, then one of A and C is 9, the other is chosen from 1 and 7. But none of 1896543, 7896543, 9816543 and 9876543 is divisible by 7.
Therefore G=7, one of A and C is 1, the other is chosen from 3 and 9. From 1836547, 1896547, 3816547 and 9816547, only 3816547 is divisible by 7 (the quotient is 545221).
Therefore, the number we are looking for is 381654729.
Hide Hint Show Hint Hide Answer Show Answer
What Next?
View a Similar Brain Teaser...
If you become a registered user you can vote on this brain teaser, keep track of which ones you have seen, and even make your own.
Solve a Puzzle
Comments
wow... very good teaser, though I thought this to be more of a Logic brainteaser than a Math brainteaser
well there is more than one number. I found the following number that also satisfy the conditions: 222.456.564
I think you are only supposed to use each of the digits 1-9 ONCE.
You can't repeat 2, etc.
I agree with the logical nature, too. I didn't do much math.
You can't repeat 2, etc.
I agree with the logical nature, too. I didn't do much math.
i actually found deciphering the sixth statement as easy, because i can actually mentally determine if a number is divisble by 7, and what remainder it would have after the division (fast)
I meant that, comparing to others, this is the hardest.
I tried to make another number - but looks like you were right, the highest I got up to was 1,620,549 without repeating digits.
Great teaser! My process of solving it was exactly the way you describe it, down to the order of checking for division by 7.
I do agree that this is more of a logic brain teaser than math...although knowing the rules for divisibility requires some minimal math knowledge.
Thanks for your puzzle.
I managed to solve it with glpsol (a free linear and mixed integer programming solver, available for most platforms). I uploaded the model file that I used to pastebin for anyone who might be interested to play with it.
http://pastebin.com/iyJxDuTA
I managed to solve it with glpsol (a free linear and mixed integer programming solver, available for most platforms). I uploaded the model file that I used to pastebin for anyone who might be interested to play with it.
http://pastebin.com/iyJxDuTA
To post a comment, please create an account and sign in.
Follow Braingle!