# Find fractional part

• MHB
Gold Member
MHB
POTW Director
Let $p$ be a prime number. Find the fractional part of $\dfrac{(p+1)!}{p^2}$.

Gold Member
MHB
Because p is prime by wilson theorem $p | (p-1)!+1$
Or $p^2| (p! + p)$
or $p^2| (p! + p) (p+1)$
Or $p^2| (p+1)! + p(p+1)$
or $(p+1)! \equiv -p(p+1) \pmod p^2$

So fractional part of $\frac{(p+1)!}{p^2}$ is same as fractional part of $\frac{-p(p+1)}{p^2}$ or is $\frac{p-1}{p}$