Fun Little Extension

If you reverse all the digits of a positive integer, is it ever possible for the resulting number to be twice the original number?

Hint: You can approach this like a cryptogram puzzle ; with three digits you would solve A B C + A B C = C B A ABC + ABC = CBA where each letter represents a digit.

Note: The problem is done in base 10.

Yes No

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

24 solutions

Relevant wiki: Cryptogram - Problem Solving

Let's approach this like a cryptogram puzzle.

ABC ABC + CBA \text{ABC} \\ \text{ABC +} \\ \overline{\text{CBA}}

Since CBA has 3 digits, A must be \leq 4.
A must also be even, because 2 × ABC 2 \times \text{ABC} is even.
Combine these two facts, and A has to be either 2 or 4.

Now look at C. The units digit of C + C must be either 2 or 4. So C has to be either 1, 2, 6, or 7.
C also has to be equal to A + A (if there's no carry over) or A + A + 1 (if there is a carry over). That means C has to be either 4, 5, 8, or 9.

Since the two lists above with the allowed values for C have no overlap, it can be concluded the answer to the question is no. \square

Moderator note:

This is easily generalizable into the full problem, because the value of B B was irrelevant to the argument. That is, we could write

A...C A...C + C...A \text{A...C} \\ \text{A...C +} \\ \overline{\text{C...A}}

where . . . ... indicates some arbitrary fixed number of digits. Then the argument above applies to any positive integer we attempt to reverse the digits on.

Very nice solution!

Javier Álvarez - 3 years, 3 months ago

Log in to reply

nope its not lol

Lucas Müller - 3 years, 3 months ago

PROBLEM: If you reverse all the digits of a positive integer, is it ever possible for the resulting number to be twice the original number?

ANSWER: Are 111, 222, 333 and 444 "positive integers"? Yes! Nowhere in the problem statement does it state that the three digits must be unique. Therefore the answer is YES, since 111+111=222, 222+222=444, 333+333=666 and 444+444=888.

Barry Mantle - 3 years, 3 months ago

Log in to reply

The numbers ought to be flipped, so the result of flipping 111 would still be 111 and that's not twice of its original number

Xiang Joey - 3 years, 3 months ago

Log in to reply

No, but 2x0=0

Paul Baron - 3 years, 3 months ago

Log in to reply

@Paul Baron 0 isn't considered as a positive integer

MegaMoh . - 2 years ago

Excellent! Another example.

Paul Baron - 3 years, 3 months ago

I read the problem incorrectly. I realized this shortly after posting the above reply but there's no way to remove or edit posts. I appreciate Joey Xiang's polite response to my mistake. In the future I'll take the time to read problem statements more carefully!

Barry Mantle - 3 years, 3 months ago

111+111=222 which is 2 times 111 and 111 is the reverse of 111

Carlos Prieto Rodríguez de Vera - 3 years, 3 months ago

Log in to reply

Let's pick 111 as our number. Now, reverse the digits. The result is 111. Is 111 twice as large as 111? No. Therefore 111 isn't a solution.

Stefan van der Waal - 3 years, 3 months ago

Are solutions restricted to base-10 integers? There are certainly base-2 solutions if you allow leading zeroes. (01 reversed is 10)

George Coyne - 3 years, 3 months ago

Log in to reply

Exactly George!

Paul Baron - 3 years, 3 months ago

We also know that B+B is in {B, 10+B} if A<5 and {B-1, 10+B-1} if A>=5. So => Bis in {0 , 9} since 0+0=0 and 9+9=18+1 =10+B-1

Nicolas Bontemps - 3 years, 3 months ago

In base 2, the number 10 = 2[in base 10] x 01.

Ipso facto, the answer is ‘yes’, not ‘no’.

Paul Baron - 3 years, 3 months ago

What if the digits are 1, 1, and 1?

Haseeb Khan - 3 years, 3 months ago

Log in to reply

Then when you reverse the digits, you don't get double the original number. Additionally, when A = 1, B = 1, and C = 1, it is untrue that 111 + 111 = 111.

Jason Dyer Staff - 3 years, 3 months ago

There are however many instances where the reversal of digits results is more than twice the original integer, but not exactly twice the original integer. (Almost any integer where C is more than twice A in A...C)

Clyde Hladky - 3 years, 3 months ago

Why must A be < or = 4? If the answer is NO then A can be any number. If the proof was for an answer of YES then restrictions might apply, but since the answer is NO, then it matters not hat integer you choose to test.

JD Livingston - 3 years, 3 months ago

Log in to reply

Because there would be a carry of 1, and the result would have more digits than the starting number.

Jason Dyer Staff - 3 years, 3 months ago

Well there are cases like 111 or 222 or 333 or 444 where it can be double when its reverse is summed up. There is no where mentioned that digits are to be distinct

srinivasan m - 3 years, 3 months ago

Log in to reply

You need the reverse itself to equal double the number, no summing.

May Elsayed - 3 years, 3 months ago

Log in to reply

That's the point! They don't got it.

Juan José Betancur Muñoz - 3 years, 3 months ago

I concur. I was initially thinking 404; 404 + 404 = 808.

Kyle Wilmouth - 3 years, 3 months ago

I tried this problem using the number 123, and no matter what, it wasn't possible to get double the number. I would rate this problem a 1 because it was simple to figure out.

Lucia Tiberio - 3 years, 3 months ago

Log in to reply

Unless you tried each and every positive number (it doesn't say it has to be a 3 digit number), you wouldn't be able to figure that out using your method (of multiplying and checking). Just because you are ignorant doesn't mean you can just say that it is "simple to figure out"

Mark Perera - 3 years, 3 months ago

@Mark Perera is correct that this isn't a proof of the problem. (Please be polite, though - we're all learning here!)

Starting with specific cases can be a good way to think of things, though. Sometimes you can almost directly transition from numbers into variables to make the problem general, although here you do need to think of all cases for the first and last digit for this to work.

Jason Dyer Staff - 3 years, 3 months ago

∞. If ∞ is reversed, go get an infinite number. and, ∞ squared is equal to ∞. so, the reverse of ∞ is equal to ∞. The answer, yes.

Daniel Reiffer - 3 years, 3 months ago

Log in to reply

I think this is a joke but in case it isn't, you cannot treat \infty as a number because it is not a number.

Piero Sarti - 3 years, 3 months ago

"Since CBA has 3 digits, A must be less than or equal to4. A must also be even, because 2 multiplied by ABC is even. Combine these two facts, and A has to be either 2 or 4."

but why can't A be equal to 0?

Simon The Great - 3 years, 2 months ago

Log in to reply

What are you proposing as the value of C, then?

You can't have 0B0 because reversing the digits needs to be twice the original number.

Jason Dyer Staff - 3 years, 2 months ago
Piero Sarti
Feb 24, 2018

Suppose such a number existed and we tried generating it. We know that a 1 < 5 a_1 < 5 and that obviously 2 a 1 2a_1 is an even digit. For the reversed integer to correspond to the original integer, the first digit of the reversed integer must be even. Since a digit greater than or equal to 5 5 would carry-over at most a 1 1 and 2 a 1 + 1 2a_1 + 1 is odd, it follows that a 2 < 5 a_2 < 5 . Now generalizing and using the same logic, we can deduce that a 1 , a 2 , a 3 , a 4 , , a n 1 , a n < 5 a_1, a_2, a_3, a_4, \cdots , a_{n-1}, a_n < 5 and thus there will be no carry over when the original integer is multiplied by 2 2 . Now that we have established this, we can pair each digit in the normal integer to a digit in the reversed integer as such:

a 1 a n a_1 \rightarrow a_n

a 2 a n 1 a_2 \rightarrow a_{n - 1}

a 3 a n 2 a_3 \rightarrow a_{n - 2}

\vdots

If we now consider just a 1 a_1 and a n a_n , because of the position of the first digits of both the original and the reversed number, it follows that 2 a 1 = a n 2a_1 = a_n . For the same reason, because of the position of the last digits of both the original and the reversed number, it follows that 2 a n = a 1 2a_n = a_1 . However we previously stated that 2 a 1 = a n 2a_1 = a_n and as a result 2 a n a 1 2a_n \neq a_1 unless a 1 , a n = 0 a_1, a_n = 0 which cant be possible because you cannot begin writing an integer with the digit 0 0 . As a result, there is no number such that if you reverse the digits of said number, the resulting integer is equal to the original number multiplied by two and the answer is No \boxed{\text{No}} .

You can use a 1 a 2 a n n \underbrace{\overline{a_1a_2\cdots a_n}}_n instead of a b c x y z \overline{abc\cdots xyz}

Vilakshan Gupta - 3 years, 3 months ago

Log in to reply

Hahaha I don't know why I didn't think of that. Many thanks

Piero Sarti - 3 years, 3 months ago

Log in to reply

Just a note, I know it's a bit pedantic but there are n+1 digits in the number a 0 . . . a n a_0...a_n . If you were to change it, I would just suggest removing a 0 a_0

Stephen Mellor - 3 years, 3 months ago

Log in to reply

@Stephen Mellor Thanks for pointing that out. By the way, no worries it's not pedantic, being consistent is important.

Piero Sarti - 3 years, 3 months ago

Log in to reply

@Piero Sarti It improves your problem and solution so you're welcome

Stephen Mellor - 3 years, 3 months ago

I'm not sure it follows 2an= a1 and 2a1=an because of the carry-over on both the first and final digit(first receiving it and the final passing it on). The answer is still the same though, a1={1,2,3,4} so an= {0,2,5,6,7} and by elimination, we find that there is not an "an" that satisfies the requirements.

Daniel Hernandez - 3 years, 3 months ago

Log in to reply

If any digit in the number were greater than or equal to 5 5 , then the resulting integer would have more than n n digits when multiplied by 2 2 . Therefore a 1 , a 2 , a 3 a n 0 , 1 , 2 , 3 , 4 a_1,a_2,a_3\cdots a_n \in {0, 1, 2, 3, 4}

Piero Sarti - 3 years, 3 months ago

Log in to reply

Not any digit, only the first digit has that constraint that's why "a1" has to be {1,2,3,4} and consequently "an"= {0,2,5,6,7} e.g 7+7 would result in 4 in the last place of the sum which corresponds to the value of a1 which is less than 5. But my point is 2an= a1 and 2a1=an doesn't follow because of the carry-over.

Daniel Hernandez - 3 years, 3 months ago

Log in to reply

@Daniel Hernandez Good point. There is actually another way you can prove that all digits have to be less than 5 5 . I will update the solution with this method of proof.

Piero Sarti - 3 years, 3 months ago

Hey suppose the number is 111 or 222 or 333 in that case it is possible

Ankur Pandey - 3 years, 3 months ago

Log in to reply

In all those numbers the reverse would be the same number, the only case of a number being twice the same number is 0 which is not positive.

Daniel Hernandez - 3 years, 3 months ago

When you say "2a1 = an and 2an = a1, so that is a contradiction" i think you have to say that this only happens with an = a1 = 0, because in this case it wouldn't be a contradiction. (The statement says positive integer, so this case is eliminated).

FFname FFnames - 3 years, 3 months ago

Log in to reply

Good point, I will change the solution.

Piero Sarti - 3 years, 3 months ago

Why 0 is not a valid solution ? Since we are dealing with positive integers, and not strictly positive ones, and that 0 is both negative and positive (at least in typical French mathematical usage) ? Moreover, I don't see why might 000 not be a valid way of writing 0, since we are just ignoring leading zero in positional notation ?

admo 120104 - 3 years, 3 months ago

Log in to reply

Ignoring the position of the zero, changes the number itself. You cannot tack off digits from the number.

Piero Sarti - 3 years, 3 months ago

I think that your initial hypothesis about all the digits of the hypothetical number being less than 5, is not correct. It is supposed to be true because the length of the number cannot increase after the sum. But if you consider carring-over you get that (for example) 437+437 = 874 that is still of 3 digits. Considering the number a 1 a 2 a 3 a n 1 a n a_1 a_2 a_3 \cdots a_{n-1} a_n , only a 1 a_1 has the constraint of being less then 5. a n a_n can have bigger values so we have, with a carry-over, the possibility of 2 a n 10 = a 1 2a_n - 10 = a_1 and 2 a n 1 + 1 = a 2 2a_{n-1}+1 = a_{2} .

Bruno Ursino - 3 years, 3 months ago

Log in to reply

I have updated my solution to explain why all digits must be less than 5 5 .

Piero Sarti - 3 years, 3 months ago

111 + 111 = 222

Carlos Prieto Rodríguez de Vera - 3 years, 3 months ago

Log in to reply

111 111 reversed is not 222 222 . You need to reverse the digits.

Piero Sarti - 3 years, 3 months ago

using this approach I did the following: since 2 a i + c i = a n i + c i + 1 2a_i + c_i = a_{n-i} + c_{i+1} , 2 a n + c n = a 0 + c 0 2a_n + c_n = a_0 + c_0 , with c 0 = 0 c_0 = 0 you can write the problem as a matrix multiplication equation

( 2 I n f l i p ( I n ) ) A = ( I n m o v e d ( I n ) ) C (2 I_n - flip(I_n) ) A = (I_n - moved(I_n)) C

where A = [ a 0 , . . . , a n ] A = [a_0,...,a_n] or digits vector, C = [ c 0 = 0 , c 1 . . . , c n ] C=[c_0 = 0,c_1...,c_n] or carries vector, I n = I_n = identity matrix of size n n , f l i p ( I n ) flip(I_n) is fliped identity matrix along vertical axis which allow to get the a n i a_{n-i} term and m o v e d ( I n ) moved(I_n) is the matrix needed to get c i + 1 c_{i+1} term on equation when applied to C C f l i p ( I n ) = [ 1 1 ] flip(I_n) = \begin{bmatrix} & & 1\\ & \ddots & \\ 1 & & \\ \end{bmatrix} m o v e d ( I n ) = [ 0 n 1 , 1 I n 1 1 0 1 , n 1 ] moved(I_n) = \begin{bmatrix} \overrightarrow{0}_{n-1,1} & I_{n-1} \\ 1 & \overrightarrow{0}_{1,n-1} \end{bmatrix} .

Then, we can get A A (our number) inverting the matrix on the left side:

A = ( 2 I n f l i p ( I n ) ) 1 ( I n m o v e d ( I n ) ) C A = (2 I_n - flip(I_n) ) ^{-1} (I_n - moved(I_n)) C

I dont plan to obtain a solution rather I want to prove that no integer solution could be found (since we need an integer solution for every a i a_i ). Let me call M n = ( 2 I n f l i p ( I n ) ) M_n = (2 I_n - flip(I_n) ) . This matrix has an specific form for odd and even values of n n .

n o d d , M n = [ 2 0 1 2 0 1 0 0 1 0 0 1 0 2 1 0 2 ] n \; odd, M_n = \begin{bmatrix} 2 & & &0 & & & -1\\ & \ddots& &\vdots & &\ddots &\\ & & 2&0 &-1 & &\\ 0 & \dots & 0&1&0 & \dots&0\\ & & -1&0 &2 & &\\ & \ddots& &\vdots & &\ddots &\\ -1 & & & 0& & & 2\\ \end{bmatrix}

n e v e n , M n = [ 2 1 2 1 1 2 1 2 ] n \; even, M_n = \begin{bmatrix} 2 & & & & & -1\\ & \ddots& & &\ddots &\\ & & 2&-1 & &\\ & & -1&2 & &\\ & \ddots& & &\ddots &\\ -1 & & & & & 2\\ \end{bmatrix}

What I want to do is to prove that M n 1 M_n^{-1} is something like M n 1 = q G n M_n^{-1} = q * G_n with G n Z G_n \in \mathcal{Z} and q Q q \in \mathcal{Q} . Using the explicit form of M n M_n is not hard to check that M n 1 = 1 3 ( 4 I n M n ) M_n^{-1} = \frac{1}{3} (4I_n - M_n) (which I found out by testing for different values of n, then proved using M n M n 1 = I n Mn Mn^{-1} = I_n ). This means that

A = 1 3 ( 2 I n + f l i p ( I n ) ) ( I n m o v e d ( I n ) ) C A = \frac{1}{3} (2 I_n + flip(I_n)) (I_n - moved(I_n)) C

All the terms of this equations are integer matrices

C C (carry over) can only have 0 0 s or 1 1 s. ( I n m o v e d ( I n ) ) (I_n - moved(I_n)) has only 0 0 s, 1 1 s and 1 -1 s ( 2 I n + f l i p ( I n ) ) (2 I_n + flip(I_n)) has only 0 0 s, 1 1 s, 2 2 s and 1 -1 s

so ( 2 I n + f l i p ( I n ) ) ( I n m o v e d ( I n ) ) C (2 I_n + flip(I_n)) (I_n - moved(I_n)) C has only integer terms but that 1 / 3 1/3 at the begining proves that no integer solution is found for A A besides trivial solution 0 0 .

Thomas Peet - 3 years, 3 months ago

Log in to reply

Very nice LaTeX.

Piero Sarti - 3 years, 3 months ago
1
2
3
4
5
max_val = int(10e7)
for i in range(1,max_val+1):
    r_num = int(str(i)[::-1])
    if abs(i*2 - r_num) < 3:
        print i, r_num, r_num-i*2

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
Answer: No
Closest matches
1 1 -1
2 2 -2
25 52 2
37 73 -1
295 592 2
397 793 -1
2995 5992 2
3997 7993 -1
29995 59992 2
39997 79993 -1
299995 599992 2
399997 799993 -1
2999995 5999992 2
3999997 7999993 -1
29999995 59999992 2
39999997 79999993 -1

lol, tried it and every successive number took more and more time to execute. Had to terminate the program.

Pooja Deshpande - 3 years, 3 months ago

I miss understood the question. I thought it should be more than twise.

Martin Hansen - 3 years, 3 months ago

ABC

ABC

CBA

B: 9+9+1=19
B is "9"

C >5 6,7,8,

A <5 2*C=A

in python: //------------------------------------------------------- for a in range(1,10): for b in range(1,10): for c in range(1,10): if 2 a == c and 2 c-10 == a: print a,c else: print "error" //------------------------------------------------------------- end is 'error'

孙 策 - 3 years, 3 months ago

You have omitted (i) the integer 0, for which the answer is ‘yes’; and (ii) the binary number 01, for which the answer is also ‘yes’. There are probably others too.

Paul Baron - 3 years, 3 months ago

Log in to reply

For (i) , 0 is not a positive number, and the OP explicitly talks about reversing a positive number For (ii) I guess you have a point

Mark Perera - 3 years, 3 months ago

The fact you tested 10e7 number doesn't prove that there is no integer with more than 7 digits that fits. It only proves that "if the integer exists it's bigger than 10e7". But there is still "IF".

Dawid Zwiewka - 3 years, 3 months ago

Log in to reply

yes, but its a cool code nevertheless

John Appleseed - 3 years, 3 months ago

True, but the pattern is recurring so I imagine it can be inferred for ranges ending > 10e7

Michael Fitzgerald - 3 years, 3 months ago

Log in to reply

Even if it's recursive and you test 10eN there is always N+1 which you didn't test so it's not prove. You can "feel" you are right and you can even be right but in mathematical terms it's not prove.

Dawid Zwiewka - 3 years, 3 months ago

I like this one because I'm a programmer and in my head, I wrote a similar program. I did not actually put the time in to write and run it but it followed the same though process. I just guessed the answer after going over a few numbers in my "internal python". I'm not the only one that tries to solve things that way instead of doing mathematical proof. For the untrained mind, the mathematical proof is much harder to do me thinks.

Olafur Gardarsson - 3 years, 3 months ago

Log in to reply

Truth is I find both mathematical proof and computation incredibly useful. I thought of this problem a few months ago before I wrote it and solved it mathematically. Before I went through the trouble of proving the statement I wanted to check if there were any solutions that we're simply very well hidden so I wrote a little C# program that did just that and set it running. Of course I found no numbers and knew that no matter how many numbers I found that didn't have this property, I would still need to check an infinite amount of other numbers to be sure. However, I think we often overlook how useful computation is in number theory as it helps us feel more sure about a problem or statement.

Piero Sarti - 3 years, 3 months ago

I think there needs to be a caveat in the statement that all the numbers can't be the same, because it actually works for all numbers that are the below integer 5; e.g. 11 + 11 = 22, 444 + 444 = 888, etc. but maybe I misunderstood the question.

Matthew Kowalski - 3 years, 2 months ago

Log in to reply

I agree with Matt. The question asked regarding a positive intiger with no other mentioned constraints on that value. It only "hinted" towards approaching it with an ABC approach. However, as Matt points out, a solution emerges by taking an AAA approach.

Ryan Wishy - 3 years, 2 months ago

Log in to reply

As I have stated multiple times on this problem the question is different. (e.g. 11 11 reversed is 11 11 and that doesn't equal 2 × 11 = 22 2\times 11 = 22 .

Piero Sarti - 3 years, 2 months ago
Ruth Mckinlay
Mar 5, 2018

I seem to have over complicated it but solved it using deductions shown below. I started with what the question has hinted for us to start:

ABC + ABC = CBA

Therefore, C+C = XA where X = 1 or 0

This gives B+B+X = YB where Y = 1 or 0

This gives A+A+Y = C

If you calculate all the B+B possibilities, you will find there is no solution where B+B = B if X=0, however if X=1 and you plug in all the possibilities for B where B+B+1 = YB, the only solution that works is when B is 9, so therefore B can only be 9

That means C has to be between 6 -9 to give us a value of X=1 (as 5+5 will give 10 and A cannot be 0).

So we know C+C = 1A and C >=6, when plugging in the numbers leads us to find that A must be 2,4,6 or 8

We also know that as B has to be 9, so we know Y =1, therefore A+A+1 = C. We can use this equation to narrow down our C and A value possibilities

If A = 2, C = 5; C cannot be 5

If A = 4, C = 9

If A = 6, C = 13; C cannot be 13

If A = 8, C = 17; C cannot be 17

We can now try the values for, A = 4, B = 9, C = 9 These values do not work, so it is not possible.

I started the same way - but then just used equations to rule out solutions. Once you find out B can only be nine, you then know you need one carry over from the C+C - hence: C+C = A +10 Similarly, the 9+9+1 creates one carry-over so that A+A+1 = C Easy enough to solve these linear equations, you will just find that C==19/3 and A==8/3, so no solution with 0 to 9 digits - hence no cigar.

Guy Duchatelet - 3 years, 3 months ago
Pooja Deshpande
Mar 4, 2018

I have a question more than a solution:

Any number can be written in terms of its place, i.e. 23 can be written as (2*10 + 3) So any number AB can be written as 10A + B

For 2 digit numbers, the question is: "In what situation will 2(10A+B) = 10B + A". When we drill the above eqn down to a fraction, we get A/B = 8/19.

Since we know that A and B are definitely single digit integers, we will never have a situation when the above ratio can occur (because the denominator is a double digit number). Hence the problem statement is false (since it says "any" number, if it is false for 2 digits, the statement is false period).

Is there a flaw in this reasoning?

You need to generalize the statement above and consider what happens with n n digits. I actually made the exact same problem you mentioned a while back it was called Fun Little Problem . The reason you can't say that if it's false for 2 digits, it's false for n n digits is because adding more digits will change the place of the last two digits depending on the total length of the number.

Piero Sarti - 3 years, 3 months ago

Log in to reply

I get you. Will ponder over this further. I seem to have stumbled over the correct answer by accident.

Pooja Deshpande - 3 years, 3 months ago

There are a few of them... 111+111=222, 222+222=444,..through.., 444+444=888. It didn't say anything about A,B, or C being unique.

Jeremy Ethridge - 3 years, 3 months ago

Log in to reply

111 111 reversed is not 222 222 . The same follows for every other example you gave. There are no numbers of this form.

Piero Sarti - 3 years, 3 months ago
Leonid Pospeev
Mar 9, 2018

Let's try to approach this as a numeric puzzle. To do so, we'll assume the initial number X has its digits a 0 , a 1 , a 2 , . . . , a n a_{0}, a_{1}, a_{2}, ... , a_{n} and hence it can be represented as X = 1 0 0 × a 0 + 1 0 1 × a 1 + 1 0 2 × a 2 + . . . + 1 0 n × a n = i = 0 n ( 1 0 i × a i ) X = 10^{0}\times a_{0} + 10^{1}\times a_{1} + 10^{2}\times a_{2} + ... + 10^{n}\times a_{n} = \sum_{i=0}^n(10^{i}\times a_{i}) Except of the first digit (an), all the digits are either one of the numbers 0, 1, 2, ... , 9. The first digit, (an) is either one of the numbers 1, 2, ... , 9. For example, the number 3451 has its digits a 0 = 1 , a 1 = 5 , a 2 = 4 , a 3 = 3 a_{0}=1, a_{1}=5, a_{2}=4, a_{3}=3 and can be represented as 3451 = 1 0 0 × 1 + 1 0 1 × 5 + 1 0 2 × 4 + 1 0 3 × 3 3451 = 10^{0}\times 1 + 10^{1}\times 5 + 10^{2}\times 4 + 10^{3}\times 3 After we swap the digits of the original number X, we'll have the number Y which is represented as Y = 1 0 0 × a n + 1 0 1 × a n 1 + 1 0 2 × a n 2 + . . . + 1 0 n × a 0 = i = 0 n ( 1 0 n i × a i ) Y = 10^{0}\times a_{n} + 10^{1}\times a_{n-1} + 10^{2}\times a_{n-2} + ... + 10^{n}\times a_{0} = \sum_{i=0}^n(10^{n-i}\times a_{i}) Given the problem definition, we can write down 2 × X = Y 2\times X = Y 2 × i = 0 n ( 1 0 i × a i ) = i = 0 n ( 1 0 n i × a i ) 2\times \sum_{i=0}^n(10^{i}\times a_{i}) = \sum_{i=0}^n(10^{n-i}\times a_{i}) Transform further this equation: 2 × i = 0 n ( 1 0 i × a i ) i = 0 n ( 1 0 n i × a i ) = 0 2\times \sum_{i=0}^n(10^{i}\times a_{i}) - \sum_{i=0}^n(10^{n-i}\times a_{i}) = 0 i = 0 n ( ( 2 × 1 0 i 1 0 n i ) × a i ) = 0 \sum_{i=0}^n((2\times 10^{i} - 10^{n-i})\times a_{i}) = 0 Next examine the term being summed, specifically its part in the parentheses: 2 × 1 0 i 1 0 n i 2\times 10^{i} - 10^{n-i} For all i non equal to n this term is even because both numbers before and after the minus are even. When i is equal to n this term is transformed as: 2 × 1 0 i 1 0 n n = 2 × 1 0 i 1 2\times 10^{i} - 10^{n-n} = 2\times 10^{i} - 1 which is apparently an odd number and has its last digit either 1 (when i=0) or 9 (when i>0). For simplicity, we can omit the case when i=0 (and n=0 too) because it means our original number X has only 1 digit and its inverse number is X as well and the problem definition gives us the equation 2 × X = X 2\times X = X which obviously has no positive integer solutions. If we now go back to the equation i = 0 n ( ( 2 × 1 0 i 1 0 n i ) × a i ) = 0 \sum_{i=0}^n((2\times 10^{i} - 10^{n-i})\times a_{i}) = 0 we see that for all i non equal to n we have the products of some even number, as shown above, and the corresponding digit of the original number X. This means all such products are even. The case when i=n gives us the last term of the summation: ( 2 × 1 0 i 1 ) × a n (2\times 10^{i} - 1)\times a_{n} Here we have the product of two numbers, the first one having its last digit 9, and the second one which can be either one of the digits 1, 2, ... , 9. Such product will give us an odd number. Hence the equation i = 0 n ( ( 2 × 1 0 i 1 0 n i ) × a i ) = 0 \sum_{i=0}^n((2\times 10^{i} - 10^{n-i})\times a_{i}) = 0 represents a summation of n even numbers (when i loops through 0 to n-1) and one odd number (when i equals n). Such summation never results in 0, and hence the equation has no solutions, which consequently means no positive integer numbers can meet the problem definition.

199 A+10 B=98 C, A is even and 2 A<9 so A is 2 or 4. If A is 2, C must be 1 or 6, but If c is 1, 2 A can't be 1, so c is 6, but because A is 2 or 4 ,2 A doesn't end în 6. If A is 4, then C is 8 or 9, but 2*C doesn't end în 4.In conclusion no A,B,C exists.

Kaya Kay
Mar 11, 2018

No!! It's never possible. Because if we look at the no. at position B , it remains unchanged. And in order to be it twice the no. before, it will always be greater than the previous B.
AB1C + AB1C = CBA . B1+B1= B . ie B > B1

William Kennedy
Mar 10, 2018

ABC + ABC = CBA. Given that B is in the same position twice when B is multiplied by 2 the last digit of this two digit number must be B. This shows B > 5 because anything less doesn’t produce a two digit number and therefore couldn’t have this property. None of the numbers 6 - 9 have this property which means that the only possibility for this being true is C produces a two digit number. If C does produce a two digit number C > 5. Using guess and check we find that a 9 X 2 + 1 = 19 which is the only number between 6-9 with this property meaning B has to be 9. It’s then a simple case of checking all the numbers 6 - 9 for C to prove that this property does not exist for any 3 digit number. There’s probably a more elegant solution than that. If there is, add a comment below! I’d love to here it!

Nilmadhab Ghosh
Mar 8, 2018

Take a number AB (such that AB+AB = BA) => 20A +2B = 10B + 2A => 9A=4B So it is not possible, for A, B both are integers, but if they are not integers they will be unable to make a number

111 digits reversed 111and 111+111=222

Roger Lounsbery - 3 years, 3 months ago
Paul Cockburn
Mar 8, 2018

Let the original number ( No ) be AB...YZ and the number with reversed digits ( Nr ) be ZY...BA

If Nr is twice No then A (as the last digit of Nr ) must be an even number.

If A=2 then for the doubling to work, Z (as the last digit of No ) would have to be 1 or 6. But 1Y...B2 is clearly less than 2B...Y1 and 6Y...B2 is more than double 2B...Y6. So Z can't be 1 or 6.

If A=4 then for the doubling to work, Z would have to be 2 or 7. But 4B...YZ doubled would have to be either 8Y...BA or 9Y...BA. So Z can't be 2 or 7.

If A=6 or A=8 then No doubled would have more digits than Nr .

And A not = 0 is assumed by the definition of No = AB...YZ

Jette Germerodt
Mar 7, 2018

when looking at digits of numbers its easier to write " A B AB " as " A 10 + B A*10+B " so you can actually calculate them. I will first prove why this cant work with a two-digit number: 2 ( A 10 + B ) = B 10 + A 2*(A*10+B) = B*10+A equals 20 A + 2 B = B 10 + A 20*A+2*B = B*10+A now subtract A from both sides 19 A + 2 B = B 10 19*A+2*B = B*10 and subtract 2*B from both sides 19 A = B 8 19*A = B*8 finally divide by 8 2.375 A = B 2.375*A = B and there you have it. whatever the 2nd digit is, the first has to be 2.375 times as much. This is impossible since digits have to be whole numbers.

Looking a bit further at the 3 digit numbers we can quickly see that they cant work either: 2 ( A 100 + B 10 + C ) = C 100 + B 10 + A 2*(A*100+B*10+C) = C*100+B*10+A in this case B will just cancel out and we have the same issue again.

I hope I could help since this is the first solution I am writing please comment if anything is unclear or incorrect. Have a nice day!

Adarsh Adi
Mar 7, 2018

Let A 1 A 2 . . . . . A n A_{1}A_{2}.....A_{n} when added with A 1 A 2 . . . . . A n A_{1}A_{2}.....A_{n} gives A n A n 1 . . . . . A 1 A_{n}A_{n-1}.....A_{1} [WHERE ALL A's ARE SINGLE DIGIT NUMBERS !!!!!] Since the first digit of our result is A n A_{n} therefore it is greater than A 1 A_{1} it also follows that A n A_{n} = 2 A 1 + 1 2A_{1}+1 or 2 A 1 2A_{1} [Since A 2 + A 2 A_{2}+A_{2} can give at most carry over 1 !!!] \Rightarrow A n + A n A_{n}+A_{n} = 10 + A 1 A_{1} [ SEE THE UNIT DIGIT OF THE NUMBERS ADDED AND THE RESULT !!!] applying the two expressions we got ,the numerical value of A 1 A_{1} and A n A_{n} comes out to be non-positive integers !!!! Which contradicts our assumption and therefore the answer is N O \boxed{NO}

Fabricio Kolberg
Mar 7, 2018

Let a 1 a 2 a 3 . . . a n a_1a_2a_3...a_n be a number (with every a i a_i being a digit) such that a n a n 1 . . . a 1 a_na_{n-1}...a_1 = ( a 1 a 2 a 3 . . . a n ) 2 (a_1a_2a_3...a_n)*2 . We must have it that a 1 a_1 is the last digit of a n 2 a_n*2 , but also less than a n a_n . That means that a n a_n cannot be less than 6, since all digits less than 6 are such that the last digit of their product by two is either greater than themselves or zero.

We are left with the options of 6,7,8, and 9 for the value of a n a_n . It can't be 6, because a number that starts with 2 can't be such that its product by two starts with 6. For a similar reason, it can't be 7, (a number that starts with 4 can't be such that its product by 2 starts with 7). It can't be 8 (any number that starts with 6 is such that its product by two starts with 1) and it can't be 9 for the same reason. Therefore, we run out of options, making such a number impossible.

Josh Grigonis
Mar 7, 2018

Brute force in python:

1
2
3
4
5
for a in range (1, 10):
    for b in range(1, 10):
        for c in range(1, 10):
            if a * 200 + b * 20 + c * 2 == c * 100 + b * 10 + c:
                print(a, b, c)

Adam Rojík
Mar 7, 2018

Since B is symetric, I can write it just as

AC+AC=CA; {A,C∊{0,1,2,3,4,5,6,7,8,9}}.

Now proof:

2AC=CA

2(10A+C)=10C+A

20A+2C=10C+A

20A+2C-2C-A=10C+A-2C-A

19A=8C

A= 19 8 \frac{19}{8} C

and that has 0 non-trivial solutions (for given ranges of A,C).

Binky Mh
Mar 6, 2018

If A B C + A B C = C B A ABC+ABC=CBA , then either:

C = 2 A C=2A or C = 2 A + 1 C=2A+1 , depending on whether B > 4 B>4 .

As C > A C>A must be true for A B C + A B C ABC+ABC to result in a 3-digit number, we can use A = 2 C 10 A=2C-10 to solve C C by substitution, which gives us either C = 20 / 3 C=20/3 or C = 19 / 3 C=19/3 respectively. Because neither of these values of C C are integers, a solution is not possible.

Paul Duey
Mar 6, 2018

Doubling an integer is the same as doubling each digit in the integer, carrying a 1 if the result > 9. So for this to work, C = 2A and A = 2C. A = 4A and C = 4C. A = C = 1. The integer is a palindrome, so reversing it does not change its value.

Shreyansh Tiwari
Mar 6, 2018

A+A=C. C+C=A. •°•. 2A/2C=C/A

C^2=A^2. HENCE THE ANSWER IS NO

A+A = C or A+A+1=C.

C+C = A or C+C=10 + A.

Your solution would be valid if you can account for the other cases.

Karan Modi - 3 years, 3 months ago
Austin Voecks
Mar 5, 2018

No solutions!

from itertools import permutations

for A, B, C in permutations(range(0, 9), 3):
    string = str(A) + str(B) + str(C)
    value = int(string)

    if str(value + value) ≡ string[::-1]:
        print(string)
        break
Joe DeAlmo
Mar 5, 2018

Since we're doubling ABC, we have two possibilities:

a. If C is even, then C = 2A.

That would mean that when we add our two numbers together, we're adding C + C = 4A.

Since 2ABC = CBA, 4A must be a number ending in A. So 4A = A, or 4A = A + 10.

4A = A only works if A = 0, which it can't because then we wouldn't be adding three-digit numbers.

So, 4A = A + 10

3A = 10

And that can't happen because A would not be an integer.

b. If C is odd, then C = 2A + 1.

That would mean that when we add our two numbers together, we're adding C + C = 4A + 2.

Since 2ABC = CBA, 4A + 2 must be a number ending in A. So 4A + 2 = A, or 4A + 2 = A + 10.

4A + 2 = A doesn't work because A would be a negative number.

So, 4A + 2 = A + 10

3A = 8

And that can't happen because A would not be an integer.

Meneghin Mauro
Mar 5, 2018

Let a = A . . . Z a=A...Z , z = Z . . A z=Z..A and let's assume 2 a = z 2a=z

Clearly comparing the first digit must be Z > A Z>A , so 2 Z = A + 10 2Z=A+10

The possible cases for A,Z are all excluded

Z A reason
5 0 number of digits would change
6 2 would be z>2a
7 4 would be z<2a
8 6 would be z<2a
9 8 would be z<2a

So this is not possible, please note that the trivial one digit solution a = z = 0 a=z=0 is not admitted

Nice LaTeX

Piero Sarti - 3 years, 3 months ago
Denis Husadzic
Mar 5, 2018

Let a n a 0 \overline{a_n\ldots a_0} be the starting number and assume that we can double it by reversing its digits, i.e.

a n a 0 + a n a 0 a 0 a n \begin{aligned} & \overline{a_n\ldots a_0}\\ + & \overline{a_n\ldots a_0}\\ \hline & \overline{a_0\ldots a_n} \end{aligned}

It's obvious that n > 0 n>0 .

We know that 2 a n a 0 2a_n \leq a_0 (it's not necessarily equality because there could have been carrying over). This implies that 4 a n 2 a 0 4a_n \leq 2a_0 and thus 2 a 0 a n 2a_0\neq a_n . It follows that 2 a 0 = a n + 10 2a_0 = a_n + 10 . Returning to 4 a n 2 a 0 4a_n \leq 2a_0 gives us 4 a n a n + 10 4a_n \leq a_n + 10 , i.e. 3 a n 10 3a_n \leq 10 . Since a n a_n must be even, it follows that a n = 2 a_n = 2 and also a 0 = 6 a_0 = 6 . But, now it's clear that we had to carry over 2 2 from adding a n 1 + a n 1 a_{n-1} + a_{n-1} . This is actually impossible (see below), so the answer is No \boxed{\text{No}} .

Let c 0 c_0 be a number that we carry over when we add a 0 + a 0 a_0 + a_0 and c i c_{i} what we carry when we add a i + a i + c i 1 a_i+a_i+c_{i-1} . The claim is that c i 1 c_i \leq 1 . We can prove it by induction. The base is clear since a 0 + a 0 < 20 a_0 + a_0 < 20 . Assume that c i 1 c_i \leq 1 . Then we have a i + 1 + a i + 1 + c i 19 a_{i+1}+a_{i+1} + c_i \leq 19 . Thus, c i + 1 1 c_{i+1} \leq 1 .

Erica Phillips
Mar 5, 2018

It is not possible as in ABC + ABC =CBA as clearly in the first line it is shown that 2C=A,hence A>C which means that A is a greater no. hence twice of that would 2A>C hence it is not possible for the resulting no. to be twice the original no.

This is incorrect. 216+ 216 = 432. You forgot that you could carry over.

Denis Husadzic - 3 years, 3 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...