## Task B-4.3.

Determine all pairs of integers that satisfy the equation

$$
x^{2}-x y+y^{2}=2 x-y
$$
## First Solution.

From $x^{2}-x y+y^{2}=2 x-y$ we get

$$
x^{2}-(y+2) x+y^{2}+y=0
$$

Since we are looking for integer solutions, the discriminant of the quadratic equation $\left({ }^{*}\right)$ must be non-negative, so $(y+2)^{2}-4\left(y^{2}+y\right) \geqslant 0$ from which, after rearranging, we get $-3 y^{2}+4 \geqslant 0$.

The solution to this quadratic inequality is $y \in\left\langle\frac{2 \sqrt{3}}{3},-\frac{2 \sqrt{3}}{3}\right\rangle$, and since we are looking for integer solutions, $y$ can take the values $-1, 0$, and $1$.

By substituting $y=-1$ into equation $\left({ }^{*}\right)$, we get the equation $x^{2}-x$, with solutions $x_{1}=0, x_{2}=1$, so the solutions to the given equation are the ordered pairs $(0,-1)$ and $(1,-1)$.

By substituting $y=0$ into equation $\left({ }^{*}\right)$, we get the equation $x^{2}-2 x=0$ whose solutions are $x_{1}=0$ and $x_{2}=2$, so the solutions to the given equation are the ordered pairs $(0,0)$ and $(2,0)$.

Finally, by substituting $y=1$ into equation $\left({ }^{*}\right)$, we get the equation $x^{2}-3 x+2=0$ whose solutions are $x_{1}=1$ and $x_{2}=2$, so the solutions to the given equation are the ordered pairs $(1,1)$ and $(2,1)$.