Problem:
Let M be the greatest integer such that both M+1213 and M+3773 are perfect squares. What is the units digit of M ?
Answer Choices:
A. 1
B. 2
C. 3
D. 6
E. 8
Solution:
Suppose M+1213=j2 and M+3773=k2 for nonnegative integers j and k. Then
(k+j)(k−j)=k2−j2=3773−1213=2560=5⋅29
Because k+j and k−j have the same parity and their product is even, they must both be even, and it follows that one of them is 5⋅2i and the other is 29−i for some i with 1≤i≤8. Solving for k gives
k=25⋅2i+29−i​
To maximize M it is sufficient to maximize k, and this will occur when i=8 and k=5⋅27+1=641. Therefore M=6412−3773, and its units digit is (E)8​.
OR
Because (n+1)2−n2=2n+1, successive terms in the sequence of squares, 1,4,9,16,…, differ by successive odd numbers; and because (n+2)2−n2=4(n+1), the terms in this sequence that are two apart differ by successive multiples of 4 . The two squares required in this problem differ by 3773−1213=2560, a multiple of 4 . It follows that the greatest such squares are two apart in the sequence of squares, so n+1=42560​=640. Therefore these squares are n2=6392 and (n+2)2=6412, and M+1213=6392. Then M=6392−1213, and its units digit is (E)8​.
Note: Shown below is a table of 5⋅2i,29−i,k,j, and M for each i (notation from the first solution). Observe that M is maximized when k is maximized.
i12345678​5⋅2i102040801603206401280​29−i256128643216842​k13374525688164322641​j12354122472156318639​M139161703−1069−63739712312399911407108​​
The problems on this page are the property of the MAA's American Mathematics Competitions