2021 APMO

1

Prove that for each real number $r>2$, there are exactly two or three positive real numbers $x$ satisfying the equation $x^2=r\lfloor x \rfloor$.

2

For a polynomial $P$ and a positive integer $n$, define $P_n$ as the number of positive integer pairs $(a,b)$ such that $a<b \leq n$ and $|P(a)|-|P(b)|$ is divisible by $n$. Determine all polynomial $P$ with integer coefficients such that $P_n \leq 2021$ for all positive integers $n$.

3

Let $ABCD$ be a cyclic convex quadrilateral and $\Gamma$ be its circumcircle. Let $E$ be the intersection of the diagonals of $AC$ and $BD$. Let $L$ be the center of the circle tangent to sides $AB$, $BC$, and $CD$, and let $M$ be the midpoint of the arc $BC$ of $\Gamma$ not containing $A$ and $D$. Prove that the excenter of triangle $BCE$ opposite $E$ lies on the line $LM$.

4

Given a $32 \times 32$ table, we put a mouse (facing up) at the bottom left cell and a piece of cheese at several other cells. The mouse then starts moving. It moves forward except that when it reaches a piece of cheese, it eats a part of it, turns right, and continues moving forward. We say that a subset of cells containing cheese is good if, during this process, the mouse tastes each piece of cheese exactly once and then falls off the table. Show that: (a) No good subset consists of 888 cells. (b) There exists a good subset consisting of at least 666 cells.

5

Determine all Functions $f:\mathbb{Z} \to \mathbb{Z}$ such that $f(f(a)-b)+bf(2a)$ is a perfect square for all integers $a$ and $b$.