Friday, December 02, 2005

How does a psychic website do THAT?

An amusing web site that correctly chooses a symbol matching the two-digit number you have chosen at random.

These things always raise two challenges - first: how does it work, second: if you can see how it works, can you explain it in such a way that others can too?

So don't read on if you'd rather work it out for yourself!

The instructions are
Take any two digit number, add together both digits and then subtract the total from your original number.

When you have the final number look it up on the chart and find the relevant symbol. [...]
First, the result of adding the two digits and subtracting them from the original is always a multiple of nine.

Why?

Well, try subtracting the left digit and the right digit in separate steps, eg

instead of
[1] 3 + 5 = 8,
[2] 35 - 8 = 27.

do
[1] 35 - 5 = 30,
[2] 30 - 3 = 27.

So the subtracting the right digit always leaves you with a round number, a multiple of 10, and subtracting the left-column digit subtracts 1 from each of those 10s, leaving you with a multiple of 9.

Now take a look at the table of symbols and note that each multiple of nine maps to the same symbol (a sun sign the first time I looked, a moon symbol the next).

Thanks to Andy Naughton for a great puzzle, and my apologies if you find this explanation far less amusing!

No comments: