### Balkan Mathematical Olympiad 2016 Solutions

1. Find all injective functions $f: \mathbb R \rightarrow \mathbb R$ such that for every real number $x$ and every positive integer $n$, $$\left|\sum_{i=1}^n i\left(f(x+i+1)-f(f(x+i))\right)\right|<2016$$
2. Let $ABCD$ be a cyclic quadrilateral with $AB<CD$. The diagonals intersect at the point $F$ and lines $AD$ and $BC$ intersect at the point $E$. Let $K$ and $L$ be the orthogonal projections of $F$ onto lines $AD$ and $BC$ respectively, and let $M$, $S$ and $T$ be the midpoints of $EF$, $CF$ and $DF$ respectively. Prove that the second intersection point of the circumcircles of triangles $MKT$ and $MLS$ lies on the segment $CD$.
3. Find all monic polynomials $f$ with integer coefficients satisfying the following condition: there exists a positive integer $N$ such that $p$ divides $2(f(p)!)+1$ for every prime $p>N$ for which $f(p)$ is a positive integer. (A monic polynomial has a leading coefficient equal to 1)
4. The plane is divided into squares by two sets of parallel lines, forming an infinite grid. Each unit square is coloured with one of $1201$ colours so that no rectangle with perimeter $100$ contains two squares of the same colour. Show that no rectangle of size $1\times1201$ or $1201\times1$ contains two squares of the same colour. (Any rectangle is assumed here to have sides contained in the lines of the grid)