How would I solve an equation of this form?
$3 \% x = 1$
I can see that 2 is a valid solution for x and I think is the only answer.
This is different though:
$3 \% x = 3$
The answer is any integer greater than 3.
And this one doesn't seem to have a valid solution:
$3 \% x = 2$
Is there some standard process for solving equations like this?
I'm ultimately trying to solve nested modulos like the below, but can ask a second question if its out of scope!
$(3 \% x) \% 2 = 1$
Thanks!
Edit: I can solve congruences in the form of $x\%5=2$, which I know the answer to be $x\equiv 2+5Z$. I can also solve nested congruences like this: $((x\%7)\%5)\%2=1$. I also know about modulus multiplicative inversion, the chinese remainder theorem and the extended euclidean algorithm. However, I don't know any techniques to solve the form in the question I've asked.