All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Just Math
The reversed numbers (Posted on 2005-09-16) Difficulty: 2 of 5
Both a and b are four-digit numbers and one is obtained from the other by reversing the digits.

Determine them, knowing that 2 * (a + b) = 5 * (b - 1).

Show your reasoning.

See The Solution Submitted by pcbouhid    
Rating: 4.5000 (4 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
More brute force | Comment 6 of 8 |

FOR a1 = 1 TO 9
 FOR a2 = 0 TO 9
  FOR a3 = 0 TO 9
   FOR a4 = 1 TO 9
    IF 2 * (1001 * (a1 + a4) + 110 * (a2 + a3)) = 5 * (1000 * a4 + 100 * a3 + 10 * a2 + a1 - 1) THEN
     PRINT a1; a2; a3; a4
    END IF
   NEXT
  NEXT
 NEXT
NEXT

 


  Posted by Charlie on 2005-09-16 19:38:29
Please log in:
Login:
Password:
Remember me:
Sign up! | Forgot password


Search:
Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (7)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2024 by Animus Pactum Consulting. All rights reserved. Privacy Information