Find integers $x$ and $y$ in each of the following cases:
(i) $314x + 785y= 157$
(ii) $314x + 785y= 314$
(iii) $314x + 785y= −1570$
(i) The gcd of 214 and 785 is conveniently 157. This means we can divide through by 157 to give
$ 2x + 5y = 1$
By inspection we have $x=3, y=-1$.
(ii) 314 is $2 \times \gcd(314,785)$.
$ 314x + 785y = 2 \times 157 $
$ 2x + 5y = 2 $
Since we have $ 2(3) + 5(-1) = 1$, we can see
$ 2(2 \times 3) + 5(2 \times -1) = 2 $
So a solution is $x = 6, y=-2$
(iii) -1570 is $-10 \times \gcd(314, 785)$.
Since we have $ 2(3) + 5(-1) = 1$, we can see
$ 2(-10 \times 3) + 5(-10 \times -1) = -10 $
So a solution is $x = 30, y=10$