1. The numbers $x, y, z \neq 0$ are such that $\frac{x^{2}+y^{2}-z^{2}}{2 x y}+\frac{y^{2}+z^{2}-x^{2}}{2 y z}+\frac{z^{2}+x^{2}-y^{2}}{2 x z}=1$.

What values can the expression

$$
\left(\frac{x^{2}+y^{2}-z^{2}}{2 x y}\right)^{2016}+\left(\frac{y^{2}+z^{2}-x^{2}}{2 y z}\right)^{2016}+\left(\frac{z^{2}+x^{2}-y^{2}}{2 x z}\right)^{2016} ?
$$

take?
Answer: 3.

Solution: Multiply by $2 x y z$, move to one side, we get $z\left(x^{2}+y^{2}-z^{2}\right)+$ $x\left(y^{2}+z^{2}-x^{2}\right)+y\left(z^{2}+x^{2}-y^{2}\right)-2 x y z=0$. Factorize: $(x+y-z)(x-$ $y+z)(-x+y+z)=0$. Therefore, one of the numbers is equal to the sum of the other two. Then the expressions in the parentheses are $\pm 1$.