Puzzle 29
If you prepend a 1 to a five digit number, the result
is exactly 3 times smaller than if you appended a 1 to
the same five digit number. What's the five digit number?
i.e. Assume a five digit number NNNNN
1NNNNN is exactly 3 times smaller than
NNNNN1. What is NNNNN?
The "professor" thinks this is too easy, but I insisted you needed a break after Puzzle 28, so
have fun. Don't let conversion from string to numeric to string to numeric to string, and so on, drive
you crazy!
Your task boys and girls is to write an xbasic script that solves this puzzle. Display your
answer in the trace window. For extra credit don't post your script in the body of a reply,
but figure out how to "export" your script to a text file, and then "attach" your text file
to your reply here.
Enjoy!
Credit for this puzzle: http://www.mathsisfun.com/
Bookmarks