This question is from textbook Introduction to Analytic Number Theory by Tom Apostol on page 127 and I am unable to solve it.
Let p be a prime. Then prove that $\binom{n}{p}$ $\equiv \lfloor\frac{n}{p}\rfloor ( \bmod p) $and also if $p^{x}$ divides $\lfloor\frac{n}{p}\rfloor $ then prove that $p^x$ divides $\binom{n}{p}$.
I tried only first part by using definition of $\binom{n}{p}$ but could not prove that it's equal to $\lfloor\frac{n}{p}\rfloor$.
Can you please help. I am self studying it and there is no one to guide.
Write $n$ in base $p$ as $n=n_0+n_1p+\ldots+n_kp^k$ for some natural number $k$ and $0\leq n_0,\ldots,n_k<p$. The binomial coefficient $$\binom{n}{p}=\frac{n!}{p!(n-p)!}=\frac{n(n-1)\cdots(n-(p-1))}{1\cdot 2\cdots p},$$ has $p$ consecutive factors in the numerator, and $p$ consecutive factors in the denominator. So both products have precisely one factor in each residue class mod $p$. In particular, both product have precisely one factor that is divisible by $p$; in the denominator this is clearly $p$, and in the numerator this is $n-n_0$. It follows that $$\binom{n}{p}=\frac{n-n_0}{p}\cdot\frac{n(n-1)\cdots\widehat{(n-n_0)}\cdots(n-(p-1))}{1\cdot2\cdots(p-2)(p-1)},$$ where 'hat' on the factor $\widehat{(n-n_0)}$ indicates that this factor is skipped in the product. Now $\frac{n-n_0}{p}$ is an integer, and the products in the numerator and denominator of the remaining fraction both range precisely over all nonzero residues mod $p$. So mod $p$ those two products are equal, and the fraction equals $1$, yielding $$\binom{n}{p}\equiv\frac{n-n_0}{p}\pmod{p}.$$ Of course it should be clear that $\frac{n-n_0}{p}=\lfloor\frac{n}{p}\rfloor$. Can you prove the second part from here?