I've stucked at the following problem:
Let $p$ be an odd prime number. Show that for all $a\in\mathbb{Z}$
$$a^p \equiv a\ (\mathrm{mod}\ 2p)$$
How can I prove it? I know within Fermat's theorem that $a^p \equiv a\ \mathrm{mod}\ p$.
I've stucked at the following problem:
Let $p$ be an odd prime number. Show that for all $a\in\mathbb{Z}$
$$a^p \equiv a\ (\mathrm{mod}\ 2p)$$
How can I prove it? I know within Fermat's theorem that $a^p \equiv a\ \mathrm{mod}\ p$.
Yes, and equivalently Fermat's theorem says that $p$ divides $a^p-a$. However, note that $a^p-a$ is also an even number, hence $2$ divides it as well. And this implies that $lcm(2,p)$ must divide $a^p-a$. But $2,p$ are coprime, so their $lcm$ is $2p$.