<s>[INST] Determine the primes p for which $6\in Q_p$(where $Q_p$ denotes quadratic residue) Background This is from Jones Elementary Number theory problem 7.12. I only want the case where $6\in Q_p$ to be worked although the original problem asks for -3,5,6,7,10,169.
Using Legendre's notation and the Quadratic reciprocity law I get:
\begin{align}
\textrm{If }P \equiv & 1 \mod 4&\\
\left(\frac{2}{p}\right)\left(\frac{3}{p}\right) &=\\
\left(\frac{p}{2}\right)\left(\frac{p}{3}\right) &\implies p \equiv  1 \mod 2 \\
&\quad \quad \;\; p \equiv  1 \mod 3 \\
\hline
Thus&\implies p\equiv 1 \mod 6\\
\end{align}
$$
\left.
\begin{array}{l}
p\equiv 1 \mod 4\\
p \equiv 1 \mod 6
\end{array}
\right\}\bbox[5px,border:1px solid red]{p \equiv 1,13 \mod 24}
$$

\begin{align}
\textrm{If }P \equiv & 3 \mod 4&\\
\left(\frac{2}{p}\right)\left(\frac{3}{p}\right) &=\\
\left(\frac{p}{2}\right)\left(-\frac{p}{3}\right) &\implies p \equiv  1 \mod 2 \\
&\quad \quad \;\; p \equiv  2 \mod 3 \\
\hline
Thus&\implies p\equiv 5 \mod 6\\
\end{align}
$$
\left.
\begin{array}{l}
p\equiv 3 \mod 4\\
p \equiv 5 \mod 6
\end{array}
\right\}\bbox[5px,border:1px solid red]{p \equiv 11,23 \mod 24}
$$
The text solution is $p \equiv \pm1 \text{ or } \pm 5 \mod 24$. What did I do wrong?
 [/INST] The Quadratic Reciprocity law only applies to odd primes $p,q$, and $2$ is not an odd prime. In fact we have
$$\left(\frac{2}{p}\right)=(-1)^{(p^2-1)/8}$$
which does not just depend on the value of $p$ mod $4$. So you will have to split the problem up into more cases.
</s>