Just out of curiosity, and this may be something trivial, but can any function $f:\mathbb{R} \rightarrow \mathbb{R}_{+} \cup \{0\}$ (other than $f\equiv 0$) give us the following inequality:
$$\forall c<a<b<d: \quad \frac{1}{b-a}\int_{a}^{b}f(x) \; \mathrm dx \leq \int_{c}^{d}f(x) \; \mathrm dx?$$
The function
$$s\mapsto \int_a^s f(x) dx$$
is continuous in $s$ (and similar for the lower bound). So let $a\to c, b\to d$, we have
$$ \frac{1}{d-c} \int_c^d f(x) dx \le \int_c^d f(x) dx.$$
Since $c, d$ are arbitrary, let $d = c+ 1/2$ gives
$$2 \int_c^{c+1/2} f(x) dx \le \int_c^{c+1/2} f(x)dx$$
Since $f$ is nonnegative, this gives
$$\int_c^{c+1/2} f(x) dx = 0$$
for all $c$. This implies that $f$ is zero "almost everywhere". (there is a precise definition for this notation, when you learn measure theory). Some examples are
$$ f(x) = \begin{cases} 1 & \text{if } x = 1,1/2,1/3,\cdots \\ 0 &\text{otherwise.}\end{cases}$$