2013 Mock AIME I Problems/Problem 15

Problem

Let $S$ be the set of integers $n$ such that $n | (a^{n+1}-a)$ for all integers $a$. Compute the remainder when the sum of the elements in $S$ is divided by $1000$.

Solution

$\boxed{857}$.

See Also