Solution
= Solution
<Euler's criterion> gives $(-1/p)=(-1)^{(p-1)/2}$. The <Legendre symbol> is multiplicative, so multiplying this sign by the result of (iv) yields
$$
\boxed{\left(\frac{-2}p\right)=\begin{cases}1,&p\equiv1,3\pmod8,\\-1,&p\equiv5,7\pmod8.\end{cases}}
$$