I need to determine all primes $p$ for which $5$ is a quadratic residue modulo p.
I think I'll need to use quadratic recprocity laws to do this, i.e., I need to need to find numbers $p$ where $x^2$ is congruent to $5 \bmod p$. I'm ok doing this for single values of $p$. But how do I find all primes for which this holds?
Thanks.
Here is a Wikipedia article. Scroll up for review about quadratic reciprocity. http://en.wikipedia.org/wiki/Quadratic_reciprocity#.C2.B15