Since 2^7 = 128 > 100, A-B < 7. Otherwise, 2^A will have at least 2 digits more than 2^B, and the problem requires they have only one digit difference.
Saying that one gets 2^B by removing the leftmost digit of 2^A means that 2^A - 2^B must be D * 10^C where D is a single digit and C > 0. (Technically C = [A*log2] but that's tangential)
2^A - 2^B, then, must be a multiple of 5 since 10^C is, or 2^A = 2^B mod 5. Well, powers of two are cyclic mod 5 with period 4 (1,2,-1,-2) so for this equation to hold, A = B mod 4 and so A-B = 4 or A-B=8 (and so on.) But since A-B < 7 (see above), only when A-B=4 can there be a solution.
The solutions for A-B=4 and C=1 can be determined by noting that C = [A*log2] so 2^A < 100 and therefore A <= 6
Since A - B = 4 and B > 0, A > 4. A=4,5,6 are the only possibilities. A=4 fails to meet the puzzle's criteria, but A=5 and A=6 both give solutions: 32 -> 2 and 64 -> 4 respectively.
Now imagine that C>1. Then by a similar argument 2^A-2^B must be a multiple of 25 (true for C>=2). Powers of 2 are cyclic mod 25 with period 20 (1,2,4,8,-9,7,-11,3,6,12,-1,-2,-4,-8,9,-7,11,-3,-6,13), so for this equation to hold, we must have A=B mod 20, or A-B = 20*k, k>0. But A-B <7, so there can be no solution here.
The only possible solutions, then, are when 2^A is a two digit number, and those two solutions are (5,1) and (6,2)
|
Posted by Paul
on 2008-10-22 18:59:53 |