Sei sulla pagina 1di 2

4

Digits of Numbers

4.1 The Last Digits of a Number


Problem 4.1.4. In how may zeros can the number 1n + 2n + 3n + 4n end for
n ∈ N?
(1998 St. Petersburg City Mathematical Olympiad)

Solution. There can be no zeros (e.g., n = 4), one zero (n = 1), or two zeros
(n = 2). In fact, for n ≥ 3, 2n and 4n are divisible by 8, while 1n + 3n is
congruent to 2 or 4 mod 8. Thus the sum cannot end in three or more zeros.
Problem 4.1.5. Find the last five digits of the number 51981 .
Solution. First, we prove that 51981 = 55 (mod 105 ). We have

51981 − 55 = (51976 − 1)55 = 55 [(58 )247 − 1]


= M[55 (58 − 1)] = M[55 (54 − 1)(54 + 1)]
= M[55 (5 − 1)(5 + 1)(52 + 1)(54 + 1)]
= M52 25 = M100,000.

Therefore 51981 = M100,000 + 55 = M100,000 + 3125, so 03125 are the


last five digits of the number 51981 . Of course, the relation a = Mb means that a
is a multiple of b.
Problem 4.1.6. Consider all pairs (a, b) of natural numbers such that the product
a a bb , written in base 10, ends with exactly 98 zeros. Find the pair (a, b) for which
the product ab is smallest.
(1998 Austrian–Polish Mathematics Competition)

Solution. Let a2 be the maximum integer such that 2a2 | a. Define a5 , b2 , and b5
similarly. Our task translates into the following: find a, b such that

T. Andreescu and D. Andrica, Number Theory, DOI: 10.1007/b11856_15, 267


© Birkhäuser Boston, a part of Springer Science + Business Media, LLC 2009
268 II Solutions, 4. Digits of Numbers

min{a5 a + b5 b, a2 a + b2 b} = 98 and ab is minimal. Since 5 | a5 a + b5 b, we


have a5 a + b5 b > 98 and min{a5 a + b5 b, a2 a + b2 b} = a2 a + b2 b = 98.
Note that if 5 | gcd(a, b), then a2 a + b2 b  = 98, contradiction. Without loss
of generality, suppose that a5 ≥ 1 and b5 = 0. Let a = 2a2 5a5 x and 2b2 y,
gcd(2, x) = gcd(5, x) = gcd(2, y) = 1. Then a5 a = a5 (2a2 5a5 x) > 98 and
a2 a = a2 (2a2 5a5 x) ≤ 98. So a5 > a2 . We consider the following cases.
(a) a2 = 0. Then b2 (2b2 y) = 98. So b2 = 1, y = 49, b = 98. Since
a5 (5a5 x) ≥ 98 and x is odd, a = 5a5 x ≥ 125 for a5 ≥ 3; x ≥ 3 and a ≥ 75 for
a5 = 2; x ≥ 21 and a ≥ 105 for a5 = 1. Hence for a2 = 0, b = 98, a ≥ 75.
(b) a2 ≥ 1. Then a5 ≥ 2. We have 2a2 5a5 x ≤ 98 and 5a5 x ≤ 49. Thus a5 = 2,
x = 1, a2 = 1, a = 50. Then b2 b = 48. Let b = 2b2 y. Then b2 (2b2 y) = 48,
which is impossible.
From the above, we have (a, b) = (75, 98) or (98, 75).

4.2 The Sum of the Digits of a Number


Problem 4.2.7. Show that there exist infinitely many natural numbers n such that
S(3n ) ≥ S(3n+1 ).
(1997 Russian Mathematical Olympiad)
Solution. If S(3n ) < S(3n+1 ) for large n, we have (since powers of 3 are divisible
by 9, as are their digit sums) S(3n ) ≤ S(3n+1 ) − 9. Thus S(3n ) ≥ 9(n − c) for
some c, which is eventually a contradiction, since for large n, 3n < 10n−c .
Problem 4.2.8. Do there exist three natural numbers a, b, c such that S(a + b) <
5, S(b + c) < 5, S(c + a) < 5, but S(a + b + c) > 50?
(1998 Russian Mathematical Olympiad)
Solution. The answer is yes. It is easier to focus on the numbers a + b, b + c,
c + a instead. Each of these has digit sum at most 4. Hence their sum 2(a + b + c)
has digit sum at most 12. However, half this a + b + c has digit sum at least 51.
The only way this can happen is if a + b + c has digits either ten 5’s and a 1
or nine 5’s and a 6. Trying the former, we take a + b + c = 105555555555 and
2(a + b + c) = 211111111110 (many other choices also work). Each of a + b,
b + c, and c + a must have digit sum 4, and they must add to 2(a + b + c), so
there can be no carries. One such choice is
a + b = 100001110000, b + c = 11110000000, c + a = 100000001110.
From these we get
a = 105555555555 − 11110000000 = 94445555555,
b = 105555555555 − 100000001110 = 5555554445,
c = 105555555555 − 100001110000 = 5554445555.

Potrebbero piacerti anche