2. Given numbers $x, y, z \in [0, \pi]$. Find the maximum value of the expression

$$
A=\sin (x-y)+\sin (y-z)+\sin (z-x)
$$
Answer: 2.

Solution 1. We can assume that $x \leqslant y$ and $x \leqslant z$, since the expression $A$ does not change under cyclic permutation of the variables. Notice that

$$
\sin (x-y)+\sin (z-x)=2 \sin \left(\frac{z-y}{2}\right) \cos \left(\frac{z+y}{2}-x\right)
$$

The argument of the sine on the right-hand side lies in $\left[-\frac{\pi}{2}, \frac{\pi}{2}\right]$, and the cosine in $[0, \pi]$, since $\pi \geqslant \frac{z+y}{2} \geqslant x$. Consider two cases.

1) $z>y$. The right-hand side will be maximized at the maximum possible $x$, i.e., when $x=y$, and the value of $A$ will be zero.
2) $z \leqslant y$. For fixed $y$ and $z$, the right-hand side will reach its maximum when $x=0$. In this case,

$$
A=\sin z-\sin y+\sin (y-z)=-\sin y+2 \sin \frac{y}{2} \cdot \cos \left(\frac{y}{2}-z\right) \leqslant 2 \sin \frac{y}{2}-\sin y \leqslant 2
$$

Thus, $A \leqslant 2$. Equality is achieved when $x=0, y=\pi, z=\frac{\pi}{2}$.

Solution 2. Let $a=x-y, b=y-z, c=z-x$. The sum of the numbers $a, b, c$ is zero, so at least one of them is non-positive. Suppose, for example, $c \leqslant 0$. Then $c \in[-\pi, 0]$, hence $\sin c \leqslant 0$. Therefore,

$$
A=\sin a+\sin b+\sin c \leqslant \sin a+\sin b \leqslant 2
$$

Equality is achieved when $x=0, y=\pi, z=\frac{\pi}{2}$.