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

Home > Numbers
Move the 3, Triple the number (Posted on 2004-03-01) Difficulty: 2 of 5
If you moved the 3 at the end of a certain large number to the beginning, it would be the same as multiplying it by 3. What is the number?

See The Solution Submitted by Gamer    
Rating: 3.2000 (5 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution another method--computer-assisted | Comment 2 of 17 |

If x is the original number then 3x is the number after the digit 3 has been moved from back to front. We set up a long division of 3 into 3x to get the original number.  It starts
 <U> 1
</U>3)3

So the next digit after the 3 in the dividend is 1, as that is the first digit in the quotient, before which the 3 was appended to make the dividend.

After a couple of turns of this we get:

  <U>103
</U>3)310
  <U>3</U>
   10
    <U>9
</U>    1

The last digit so far is 3, but this is not the end, as it still leaves a remainder of 1. We must continue until the last digit is 3 but there is no remainder.  The following program continues the algorithm:
divisor = 3
temp = 3
quot$ = ""
DO
  q = temp \ divisor
  r = temp MOD divisor
  quot$ = quot$ + LTRIM$(STR$(q))
  IF q = 3 AND r = 0 THEN EXIT DO
  temp = r * 10 + q
LOOP

PRINT quot$
and finds 1034482758620689655172413793
 (with commas, that's 1,034,482,758,620,689,655,172,413,793).


  Posted by Charlie on 2004-03-01 10:44:05
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 (3)
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