Proving $10^n \equiv 1 \pmod 3$ for all $n\geq 1$ by induction 
Prove that $10^n \equiv 1 \pmod 3$ for all positive integers $n$ by mathematical induction.

Can someone please help me in solving this problem and explain what's going on? Any guidance would be greatly appreciated. 
 A: base case $n = 1 \Rightarrow 10 \equiv 1\mod 3$ holds. Assume that holds for $n = k$. Then for $n = k+1$, we have: $$10^{k+1} \mod 3 = (10\mod 3)*(10^{k}\mod 3) = (10^k \mod3) \equiv 1\mod 3$$
notice that $10^k$ holds by the induction hypothesis. 
A: Here is perhaps a more straightforward inductive proof: Let $S(n)$ denote the claim
$$
S(n) : 10^n\equiv 1\pmod{3}\Longleftrightarrow 10^n-1=3m, m\in\mathbb{Z}.
$$
Base case ($n=1$): $S(1)$ says that $10^1-1=3m, m\in\mathbb{Z}$, and we know this is true because $10^1-1=9=3(3)$. 
Inductive step: Fix some $k\geq 1$ and assume that $S(k)$ is true where
$$
S(k) : 10^k\equiv 1\pmod{3}\Longleftrightarrow 10^k-1=3\ell, \ell\in\mathbb{Z}.
$$
To be shown is that $S(k+1)$ follows where
$$
S(k+1) : 10^{k+1}\equiv 1\pmod{3}\Longleftrightarrow 10^{k+1}-1=3\eta, \eta\in\mathbb{Z}.
$$
Beginning with the left-hand side of $S(k+1)$,
\begin{align}
10^{k+1} &= 10^k\cdot 10\tag{by definition}\\[0.5em]
&= (3\ell +1)\cdot 10\tag{by $S(k)$, the ind. hyp.}\\[0.5em]
&= 30\ell + 10\tag{expand}\\[0.5em]
&= 3(10\ell+3)+1\tag{rearrange}\\[0.5em]
&= 3\eta+1, \tag{$\eta=10\ell+3; \eta\in\mathbb{Z}$}
\end{align}
we end up at the right-hand side of $S(k+1)$, thus completing the inductive step.
By mathematical induction, $S(n)$ is true for all $n\geq 1$. $\blacksquare$
