Problem

Source: Kyiv City MO 2022 Round 2, Problem 10.4

Tags: number theory, polynomial, algebra



Prime $p>2$ and a polynomial $Q$ with integer coefficients are such that there are no integers $1 \le i < j \le p-1$ for which $(Q(j)-Q(i))(jQ(j)-iQ(i))$ is divisible by $p$. What is the smallest possible degree of $Q$? (Proposed by Anton Trygub)