Bunuel wrote:
If x and n are integers such that x = 1^2 + 2^2 + 3^2 + . . . + n^2, what is the remainder when x is divided by 5?
(1) n is an even integer with a units digit less than 6.
(2) The units digit of n is 2.
(1) n=10 -----> 1 + 4 + 9 + 6 + 5 + 6 + 9 + 4 + 1 + 0 = 1 - 1 - 1 + 1 + 0 +1 - 1 - 1 + 1 + 0 = 0
n=20 -----> pattern repeats 2 times 0 + 0 = 0
...
n=2 ---> 1 + 4 = 5
n=12 ----> 0 + 0 = 0
...
n=4 ----> 1 + 4 + 9 + 6 = 1 - 1 - 1 + 1 = 0
n=14 -----> 0 + 0 = 0
...
Sufficient
(2) Single case from previous example. Sufficient.
Answer D
Another approach:
\(1^2 + 2^2 + 3^2 + 4^2 + 5^2 + 6^2 + 7^2 + 8^2 + 9^2 + 10^2 + 11^2 + 12^2 + ... =\)
\(= 1^2 + 2^2 + 3^2 + 4^2 + 5^2 + 6^2 + 7^2 + 8^2 + 9^2 + 0^2 + 1^2 + 2^2 + ... =\)
\(= 1^2 + 2^2 + (-2)^2 + (-1)^2 + 0^2 + 1^2 + 2^2 + (-2)^2 + 0^2 + 1^2 + 2^2 + ... =\)
\(= 1 + 4 + 4 + 1 + 1 + 4 + 4 + 1 + 0 + 1 + 4 + 4 + 0 + 1 + 4 ... =\)
\(= 1 - 1 - 1 + 1 + 1 - 1 - 1 + 1 + 0 + 1 - 1 - 1 + 0 + 1 - 1 ...\)
Units digits 0, 2 and 4 will give us clusters of 2, 4, 10
2 = 1 - 1 = 0
4 = 1 - 1 - 1 + 1 = 0
10 = 1 - 1 - 1 + 1 + 1 - 1 - 1 + 1 + 0 = 0
All the rest is just a combination of previous three.