Problem

Source: Romanian National Olympiad 2019 - Grade 11 - Problem 1

Tags: function, calculus, real analysis



Let $f:[0, \infty) \to \mathbb{R}$ a continuous function, constant on $\mathbb{Z}_{\geq 0}.$ For any $0 \leq a < b < c < d$ which satisfy $f(a)=f(c)$ and $f(b)=f(d)$ we also have $f \left( \frac{a+b}{2} \right) = f \left( \frac{c+d}{2} \right).$ Prove that $f$ is constant.