Problem

Source: Bosnia and Herzegovina EGMO TST 2019 p1

Tags: algebra, system of equations



Let $x_1,x_2, ..., x_n$ be non-negative real numbers. Solve the system of equations: $$x_k+x_{k+1}=x^2_{k+2}\,\,,\,\,\, (k =1,2,...,n),$$where $x_{n+1} = x_1$, $x_{n+2} = x_2$.