Problem

Source: 2022 Thailand Online MO P10

Tags: function, Functional Equations, algebra, number theory, functional equation



Let $\mathbb{Q}$ be the set of rational numbers. Determine all functions $f : \mathbb{Q}\to\mathbb{Q}$ satisfying both of the following conditions. $f(a)$ is not an integer for some rational number $a$. For any rational numbers $x$ and $y$, both $f(x + y) - f(x) - f(y)$ and $f(xy) - f(x)f(y)$ are integers.