I am trying to solve the following exercise:
Let $f$ be integrable. Assume that $\int_A f d\mu = 0$ for every measurable set $A$. Prove that $f = 0$ a.e. [$\mu$].
I have the following proof but it seems to me too simple to be true. What is wrong with it?
For any $a>0$, define $W_a:=\{w|f(w)\geq a\}$. Now we have: $$\int_{W_a} fd\mu = 0 \geq \int_{W_a} ad\mu=a\mu(W_a)$$ and therefore $\mu(W_a)=0$. Same holds for the negative $a$'s. This completes my proof.
Indeed, your proof shows that $\{f > 0\}$ has measure zero. Similarly, you show $\{f < 0\}$ has measure zero, and hence $f=0$ a.s. Yes it really is this easy.