I started reading a book about number theory, and in one of the excersises I needed to prove that $30|n^5-n$ for any $n$. Using the division algorithm I managed to show that $2|n^5-n$, $3|n^5-n$ and that $5|n^5-n$, and so $30|n^5-n$ as requested.
The prove for $5|n^5-n$ (which is the most complex) went as follows: $$n = 5q + r \Rightarrow n^5 = (5q + r)^5 \Rightarrow n^5 = 5m + r^5 \Rightarrow n^5 - n = 5m - 5q + r^5 - r$$ where $q > 0$, $0 \le r < 5$ and $m$ is some number.
For this to divide by five I need that $5|r^5 - r$, so I iterated over every possible $r$ and checked.
I also managed to prove that $42|n^7 -n$ for every $n$ in the same way.
This process led to some questions:
$1$. Is there a way to shorten this process? I noticed just later that the divisibility by five can easily be proved using Fermat's little theorem, and I did use some basic modular arithmetics to shorten the calculations, but I still need to go over quite a few numbers. $2$. How can I prove that a certain number is the g.c.d of a group defined by a polynomial like this? If I have a group $A_k = \{n|\exists m: n = m^k - m \}$ how can I prove that some number $g$ is the g.c.d of the group? Can I generalize this for other polynomials? $3$. How can I find the g.c.d of such a group?