Problem

Source: 2019 Baltic Way P4

Tags: algebra



Determine all integers $n$ for which there exist an integer $k\geq 2$ and positive integers $x_1,x_2,\hdots,x_k$ so that $$x_1x_2+x_2x_3+\hdots+x_{k-1}x_k=n\text{ and } x_1+x_2+\hdots+x_k=2019.$$