The first one you need merely prove that so that Fermat's applies. The second one would be nice if this was group theory! Otherwise, note that by the division algorithm we have that for some . So and since with only if we may conclude that . The last one is up to you, son.
To be more precise: the theorem states for any coprime with p we have:
mod p
Observe :gcd(10, p) = 1 , 10 and p are coprime since
(b) It's known that is a cyclic group of order p-1. Thus if k is the smallest number such that mod p then ord . Hence k|p-1 in the group
(c) is a consequence of long division.
(ehr..sorry drex. my post has just become useless ;p)
Let
We have mod p
etc.
That is how we apply the long division algorithm:
Observe:
mod p
mod p
mod p
mod p
mod p
From this follows that
(and the cycle repeats again)
Guess we still have to prove there's no sub-period