We can just prove it by cases: either X ≥ Y occurs or Y > X occurs, and in either case the LHS is ≥ 0, since f and g are increasing functions.

Same is true (replacing X by x and Y by y) if x and y are just real numbers in the domain of f and g if f and g are functions defined on a subset of the reals.

## Bookmarks