<s>[INST] Factoring out a $7$ from $3^{35}-5$? Please Note: My main concern now is how to factor $7$ from $3^{35}-5$ using Algebraic techniques, not how to solve the problem itself; the motivation is just for background.
Motivation:
I was trying to solve the following problem

What is the remainder when $10^{35}$ is divided by $7$? 

I used the binomial formula: $\dfrac {(7+3)^{35}}{7}= \dfrac {7^{35} + \cdot \cdot \cdot 3^{35}}{7}= \dfrac {7^{35} + \cdot \cdot \cdot + 35 \cdot 3^{34} \cdot 7}{7}  + \dfrac {3^{35}}{7}$
Therefore, $10^{35}$ will have the same remainder as $3^{35}$ when divided by $7$. 
I was stuck here, and I wanted to try to reverse engineer the answer. I know the remainder is $5$. Therefore I should be able to write $3^{35} -5 + 5$ as $7k+5$. However, I have no idea how to factor out a $7$ from $3^{35}-5$, or from $10^{35}-5.$ How could I find this $k$ non-explicitly?
 [/INST] You can use the fact that the remainder of $ab$ is the remaineder of $a$ multiplied by the remaineder of $b$. So forgeting factors of $7$, we have $3^{35}=27*3^{32}=6*(9)^{16}=6*2^{16}=6*(16)^4=6*2^4=6*2=5$
</s>