Stuck setting up a two-digit number puzzle

I’m working on a number puzzle and I think I have the right setup, but I’m not fully confident about the reasoning.

The puzzle says: a two-digit number is 4 times the sum of its digits. If 18 is added to the number, the digits are reversed. I’m trying to solve it using algebra rather than guessing.

My attempt is to let the tens digit be a and the ones digit be b, so the number is 10a + b. Then I wrote:

10a + b = 4(a + b)

and for the reversing part:

10a + b + 18 = 10b + a

This feels correct to me, but I’m getting a bit unsure about whether I’m translating the second condition properly. I also keep wondering if there are hidden digit restrictions I should be using from the start, like a cannot be 0 and both digits must be whole numbers from 0 to 9.

Am I setting up the equations in the right way, and what is the best next step without just guessing numbers? Any help appreciated!

4 Responses

  1. Your setup is spot on: from 10a+b=4(a+b) we get 2a=b (so a must be even), and from 10a+b+18=10b+a we get b=a+2, with a in 1–9 and b in 0–9.
    Solving b=2a and b=a+2 gives a=2, b=4, so the number is 24-and 24+18=42, like two socks swapping feet after an 18-step tango.

  2. Your setup is spot on: if the tens digit is a and the ones digit is b, then the number is 10a + b, and your two equations 10a + b = 4(a + b) and 10a + b + 18 = 10b + a are exactly the right translations (and yes, remember the digit rules: a is 1–9 and b is 0–9). Now do a little algebra waltz: from the first equation, 10a + b = 4a + 4b simplifies to 6a = 3b, so b = 2a. From the “flip the digits” equation, 10a + b + 18 = 10b + a simplifies to 9a − 9b = −18, so a − b = −2, i.e., b = a + 2. Put those two together-b = 2a and b = a + 2-and you get 2a = a + 2, hence a = 2 and then b = 4. Quick check (the tiny worked example!): the number 24 is four times the sum of its digits since 2 + 4 = 6 and 4 × 6 = 24, and adding 18 gives 42, which is 24 with its digits doing a neat little backflip. Also, since b = 2a, the digit restriction quietly tells us a can’t be bigger than 4 (or b would exceed 9), which is a nice built-in sanity check. So the unique answer is 24-tidy, satisfying, and obedient to all the rules.

  3. Your setup is spot on! Letting the number be 10a + b with a as the tens digit and b as the ones digit is exactly the right start, and yes-those “hidden” restrictions are real: a must be 1–9 and b must be 0–9, both integers. From your first equation, 10a + b = 4(a + b) simplifies to 6a = 3b, so b = 2a. That already tells us b is even and limits a to at most 4 (since b can’t exceed 9).

    Now use your second equation: 10a + b + 18 = 10b + a simplifies to 9a + 18 = 9b, so b = a + 2. Combine that with b = 2a to get 2a = a + 2, which gives a = 2 and then b = 4. The number is 24. Quick check: sum of digits is 6, four times that is 24; add 18 and you get 42, which is the reverse-perfect. Nicely set up, and the algebra leads you there without guessing.

    Out of curiosity, which step felt the most “wobbly” to you-the reversal equation, or trusting the digit constraints? And if you like these, what do you think would change if we tried a three-digit version with the same kind of rules?

  4. Love your setup-treat the “reverse” like a price tag flipping: from 10a+b=4(a+b) we get b=2a, and from 10a+b+18=10b+a we get b=a+2, so a=2, b=4 and the number is 24 (digits already in 0–9 with a≠0), and 24+18=42 checks. What do you think would happen if we changed the +18 to another even number-would the same method still land a unique answer?

Leave a Reply

Your email address will not be published. Required fields are marked *

Solve Puzzles. Win £200!

Complete our free Puzzle Packs to earn entries into our quarterly £200 cash prize draw. Every different pack you complete gives you another chance to win!

Choose a Pack

Explore our collection of free Puzzle Packs and find your next maths challenge.

Solve the Puzzles

Complete every puzzle in your chosen pack to earn one competition entry.

Be in With a Chance!

Every completed pack gives you another entry into our quarterly £200 prize draw.

Join Our Community

Ready to make maths more enjoyable, accessible, and fun? Join a friendly community where you can explore puzzles, ask questions, track your progress, and learn at your own pace.

By becoming a member, you unlock:

  • Access to all community puzzles
  • The Forum for asking and answering questions
  • Your personal dashboard with points & achievements
  • A supportive space built for every level of learner
  • New features and updates as the Hub grows