This is an exercise in Bartle & Sherbert's Introduction to Real Analysis second edition.
They ask to show that if $I=[a,b]$ is a closed bounded interval and that $f:I\to\mathbb{R}$ is (Riemann) integrable on $I$, then $|f|$ is integrable on $I$. Of course we know that the composition of an integrable function with a continuous function is integrable, but here they ask to prove it directly using the inequality $$|f(x)|-|f(y)|\leq|f(x)-f(y)|,\quad\forall x,y\in I.$$ By the Riemann's Criterion, $\epsilon>0$ given, there exists a partition $P$ of $I$ such that the difference between the upper and lower sum is less than $\epsilon$, i.e. $$U_f(P)-L_f(P)<\epsilon.$$ So if we can show that $$U_{|f|}(P)-L_{|f|}(P)\leq U_f(P)-L_f(P)$$ then we would be done. But I can't see how to prove this last inequality.