= Solution
For a nonnegative measurable $f$, define
$$
f_n(x)=2^{-n}\left\lfloor2^n\min(f(x),n)\right\rfloor.
$$
Each $f_n$ takes only finitely many values, its level sets are measurable, and $f_n(x)\to f(x)$ pointwise. Thus measurable nonnegative functions are pointwise limits of <approximation by nonnegative simple functions>[simple functions].
If $f$ is integrable, the same functions satisfy $0\leq f_n\leq f$ and converge pointwise. The <dominated convergence theorem> gives
$$
\int_E|f_n-f|\,d\mu\longrightarrow0.
$$
They are integrable because they are bounded above by $f$.
If $0\leq f\leq M$, instead set
$$
g_n=2^{-n}\lfloor2^nf\rfloor.
$$
This has finitely many values and
$$
0\leq f-g_n<2^{-n}
$$
everywhere, so $g_n\to f$ uniformly.
Back to article page