I don't know if I'm correct, since I didn't even have to use the hint. So I'm asking for proof verification since I am also not too confident on primes.
Suppose $\gcd(a, 35) = 1.$ Show that $a^{12} - 1$ is divisible by $35$.
Here's the hint that wasn't applied. How would I have applied it?
(HINT) Factor $12$ as $2*6$ and apply Fermat's Little Theorem for $p = 7$. Then factor as $4*3$ and use $p = 5$.
We want to show $35\mid a^{12}-1$, equivalent to $$a^{12} \equiv 1 = 1 \pmod{35}$$
So $(a^{12})^2 = a^{24} \equiv 1^2 = 1 \pmod{35}$ as well. But $\phi(35) = 24$, and $a, 35$ are coprime numbers - so by Fermat's Little Theorem, we have $35\mid a^{12}-1$.
Here is another one:
Use Fermat's Little Theorem to find the unit digit of $3^{100}$.
(HINT) Use $p = 5$ and consider parity.
Assume
$$3^{100} \equiv a \pmod 5$$
But we have $3^2 \equiv -1 \pmod 5$ so $3^{100} \equiv 1 \pmod 5$. Thus the units digit is $1$.