# A theorem about binomial coefficient module prime

For any integer $r$ and prime $p$, there is a integer $n$ which $\binom{2n}{n}\equiv r \pmod{p}$.

I tried Lucas's theorem, but I was stuck.

Suppose $r\neq 0$, otherwise we can let $n=p$.

Let $n=\overline{n_m\cdots n_2n_1n_0}_p$, by Lucas's theorem,

for any $n_i(0 \leq i \leq m)$, we have $2n_i< p$,

otherwise $2n_i \bmod{p} < n_i \bmod{p}$, that implies $\binom{2n}{n}\equiv 0 \pmod{p}$. Contradiction!

And after this step I can't get any progress.

• Well, here are some interesting things: The sum of $\binom{n}{m}^2$ is equal to $\binom{2n}{n}$, and $\binom{n}{p}$ divided by $p$ has a residue of $[\frac{n}{p}]$. – S.C.B. Feb 23 '16 at 9:40