Let $V_p$ be the $p$-adic valuation. We know that $(p - 1)! + 1\equiv0\mod p$ for the prime $p$ by Wilson's theorem. I wonder if there is an upper bound for $V_p((p - 1)! + 1)$.
Also I do not know how to prove the following statement: Let $p\equiv 7\mod8$ be a prime. Then $\sum\limits_{r = 1}^{\frac{p - 1}{2}}r(\frac{r}{p}) = 0$, where $(\frac{\cdot}{\cdot})$ is the Legendre symbol.
Could anybody help me to answer these questions? Thanks.