A treasure chest is secured by a digital padlock requiring a four-digit code. The code contains no repeating digits. The sum of the first and third digits equals the second digit. The fourth digit is three times the first digit. The middle two digits add up to 9. What is the four-digit code?
2536
Let digits be A, B, C, D. D = 3A. Since D must be a single digit (0-9), A can be 1, 2, or 3. If A=2, D=6. B+C=9. A+C=B -> 2+C=B. Substituting: (2+C)+C=9 -> 2C=7 (not integer). Let's re-verify: A=2, D=6, B+C=9, A+C=B -> B=2+C. Substitute into B+C=9 -> (2+C)+C=9 -> 2C=7 (wait, let's use A=1: D=3, A+C=B -> 1+C=B. B+C=9 -> (1+C)+C=9 -> 2C=8 -> C=4. Then B=5, D=3. Code: 1543. Let's check: A=1, B=5, C=4, D=3. A+C=1+4=5 (B). D=3 (3*1). B+C=5+4=9. No repeating digits: 1, 5, 4, 3. Correct answer is 1543.
About this riddle
Logic riddles give you a few facts and ask what must be true. List what you know, cross out what cannot be, and see what is left.
Difficulty: Medium. More like this: Logic riddles with answers or try Einstein's Logic Grid for a different kind of puzzle.
More logic riddles
Five people are standing in a line to buy ice cream. Alice is neither first nor last. Bob is standing somewhere behind Charlie. David is standing directly behind Alice. Emily is standing first in line. What is the exact order of the line from front to back?
You have three closed boxes labeled 'Apples', 'Oranges', and 'Mix'. Every label is guaranteed to be wrong. You are allowed to pull out only one fruit from only one box without looking inside. Which box should you pick a fruit from to correctly identify the contents of all three boxes?
A drawer contains loose red, blue, and green socks. If you pull socks out one by one without looking, what is the minimum number of socks you must remove to guarantee getting a matching pair?
Three friends—Leo, Mia, and Noah—each brought a different pet to a park: a ferret, a parrot, and a turtle. Leo is allergic to feathers. Noah does not own a shell or feathers. Mia's pet can talk. Which pet did Noah bring?
The flag is bigger than the parade float, and the firework is bigger than the flag. Which one is the middle size?
A farmer needs to cross a river with a wolf, a goat, and a cabbage. The boat can only hold the farmer and one item at a time. The wolf will eat the goat if left alone, and the goat will eat the cabbage if left alone. However, the wolf is afraid of water and will not cross if left unattended on a bank with the cabbage. Wait—the wolf eats the goat, the goat eats the cabbage, but the wolf won't touch the cabbage. What is the minimum number of one-way boat trips required to get all three across?

