<s>[INST] Show that $2^{105} + 3^{105}$ is divisible by $7$ I know that $$\frac{(ak \pm 1)^n}{a}$$ gives remainder $a - 1$ is n is odd or $1$ is n is even.
So, I wrote $ 2^{105} + 3^{105}$ as $8^{35} + 27^{35}$ and then as $(7\cdot 1+1)^{35} + (7\cdot 4-1)^{35}$, which on division should give remainder of $6$ for each term and total remainder of 5 (12/7).
But, as per question, it should be divisible by 7, so remainder should be zero not 5. Where did I go wrong?
[note: i don't know binomial theorem or number theory.]
 [/INST] You can write $2^{105} = 2^{6 \cdot 17}\cdot 8$ and $3^{105} = 3^{6 \cdot 17} \cdot 3^3$ and you can use Fermat's little theorem.
$2^{6 \cdot 17} \equiv 1 \pmod 7$, $8 \equiv 1 \pmod 7$ therefore $2^{2015} \equiv 1 \pmod 7$ while $3^{6 \cdot 17} \equiv 1 \pmod 7$ and $3^3 \equiv 6 \pmod 7$ therefore $3^{105} \equiv 6 \pmod 7$. $2^{105} + 3^{105}\equiv 1 + 6 \equiv 7 \equiv 0 \pmod7.$ We demonstrated that the number is divisible for $7.$
</s>