I don't understand how to do these 2 tasks:
1) Prove that any arithmetic progression modulo $n$ has a period that divides $n$.
2) Prove that any geometric progression modulo a prime number $p$ has a period that divides $p-1$.
A progression modulo some number $n$ is when you have a progression and then you replace every $a_i$ by $a_i\mod n$.
A period is the number of elements in the smallest repeated sub-sequence, for example $...1,2,3,1,2,3...$ has period $3$.
In the first task, if we have a progression with difference $d$, and $d$ and $n$ are relatively prime, then the period will be $n$ because $1$ is the greatest common divisor and that's why all elements ($0,...,n-1$) will be repeated but I don't understand how to prove for the general case. Maybe when the gcd is some other number $k$, it means that every $k-th$ number will be present in the repeated sub-sequence and the $n/period=k$?