AMC10 2019 10A, Problem 9

What is the greatest three-digit positive integer $n$ for which the sum of the first $n$ positive integers is $\underline{not}$ a divisor of the product of the first $n$ positive integers?

Solution: The sum of the first $n$ positive integers is $\frac{(n)(n+1)}{2}$, and we want this not to be a divisor of $n!$ (the product of the first $n$ positive integers). Notice that if and only if $n+1$ were composite, all of its factors would be less than or equal to $n$, which means they would be able to cancel with the factors in $n!$. Thus, the sum of $n$ positive integers would be a divisor of $n!$ when $n+1$ is composite. (Note: This is true for all positive integers except for 1 because 2 is not a divisor/factor of 1.) Hence in this case, $n+1$ must instead be prime. The greatest three-digit integer that is prime is $997$, so we subtract $1$ to get $n=\fbox{996}$.

Answer: 996