Find the least positive residue of $10^{515}\pmod 7$. I tried it, but being a big number unable to calculate it.

$10^{6} \equiv 1 $ mod $7$ By Fermat's little theorem.  Notice $515=6 \times 85+5$ so $10^{515} \equiv 10^{5}$ mod $7$. Notice $10 \equiv 3$ mod 7, so $10^{2} \equiv 3^{2} \equiv 2$ and $10^{3} \equiv 20 \equiv -1\equiv 6$ mod $7$, $10^{4} \equiv 60 \equiv 4$ mod $7$, so $10^{5} \equiv 40 \equiv 5$ mod $7$. So $10^{515}\equiv 5$ mod $7$
