Problem

Source: European Girls’ Mathematical Olympiad 2014 - Day 2 - P4

Tags: modular arithmetic, number theory, EGMO, EGMO 2014, Divisibility



Determine all positive integers $n\geq 2$ for which there exist integers $x_1,x_2,\ldots ,x_{n-1}$ satisfying the condition that if $0<i<n,0<j<n, i\neq j$ and $n$ divides $2i+j$, then $x_i<x_j$.