3 Answers
3

HINT: $x,y$ have the same reminder when divided by $d$ if and only if $d$ divides $x-y$.

Once you prove this, the claim follows immediately observing that $x,y,z$ have the same reminder when divided by $d$ if and only if all three pair, $x,y$; $x,z$ and $y,z$ have the same remainder when divided by $d$; if and only if $d$ divides $x-y, x-z, y-z$.

Conversely, suppose that $b$ divides the gcd of $x-y$, $x-z$, and $y-z$. Then $b$ divides $x-y$, hence the remainder of dividing $x$ and $y$ by $b$ is the same; and similarly, the remainer of dividing $x$ and $z$ by $b$; and of dividing $y$ and $z$ by $b$, is the same.

Thus, an integer leaves the same remainder when dividing $x$, $y$, and $z$, if and only if it divides $\gcd(x-y,y-z,z-x)$.