Add the modulus to :
Since , we can cancel both sides by 2 without worrying about the modulus.
Congruence ax = b (mod c) for some a, b, c in Z can be written as a linear diophantine equation ax - cy = b. And that is easy to solve using the box method.
For this problem, 2x = 7 (mod 17) can be written as 2x - 17y = 7.
Using the box method, we found the Bezout relation: -56.2 + 7.17 = 7
Therefore, x = -56 = 12 (mod 17).