For each positive integer $n$, let $f(n) = n^4 - 360n^2 + 400$. What is the sum of all values of $f(n)$ that are prime numbers?
To find the answer it was enough to play around with $f$. One can easily find that $f(1)=41$ is a prime, then $f$ becomes negative for $n$ between $2$ and $18$, and then $f(19)=761$ is again a prime number. And as $41 + 761 = 802$ is already the largest option, the answer must be $\fbox{802}$.