This present question is inspired by this earlier question.
Consider the problem of proving that if $f\ge 0$ on an interval $I\subseteq\mathbb R$ and $\int_I f=0$, then $f$ is $0$ (almost) everywhere on $I$.
Can it be proved that the only way to prove this is by contradiction?
PS: How about if we consider two cases: (1) $f$ is continuous (and then disregard the word "almost"); (2) $f$ is measurable.
This can be avoided by considering the logical truth: $$\text{there exists }a\in I \text{ such that }f(a)\neq 0\lor f \text{ is the null function}.$$
This of course assumes that the above statement is in fact a logical truth, but that's dependent on the law of excluded middle which is equivalent to the principle of noncontradiction.
– Git Gud Jul 27 '13 at 18:09