ProofWiki:Sandbox

Theorem
Let $I$ and $J$ be intervals.

Let $f: I \to J$ be a monotone   real function.

Let $f \left[{ I }\right]$ be everywhere dense in $J$, where $f \left[{ I }\right]$ denotes the  image of $I$ under $f$.

Then $f$ is continuous on $I$.

Proof
Let $f \left({ c^{-} }\right)$ and $f \left({ c^{+} }\right)$ denote $\displaystyle \lim_{ x \to c^{-} } f \left({ x }\right)$ and $\displaystyle \lim_{ x \to c^{+} } f \left({ x }\right)$, respectively.

Suppose $f$ is increasing.

Suppose $f$ is discontinuous at $c \in I$.

Since Discontinuity of Monotonic Function is Jump Discontinuity and $f$ is increasing:
 * $ f \left({ c^{-} }\right) < f \left({ c^{+} }\right)$

Since $f$ is increasing:
 * $ f \left({ c^{-} }\right) \leq f \left({ c }\right) \leq f \left({ c^{+} }\right)$

If $ f \left({ c^{-} }\right) = f \left({ c }\right) = f \left({ c^{+} }\right)$, then $c$ is not a discontinuity.

So $f \left({ c^{-} }\right) \neq f \left({ c }\right) \lor f \left({ c }\right) \neq f \left({ c^{+} }\right)$.

Since $ f \left({ c^{-} }\right) \neq f \left({ c^{+} }\right)$:

From Real Numbers are Uncountable:
 * $ \left({ f \left({ c^{-} }\right), \,.\,.\, f \left({ c^{+} }\right) }\right)$ is infinite.

From Relative Difference between Infinite Set and Finite Set is Infinite:
 * $ \left({ f \left({ c^{-} }\right), \,.\,.\, f \left({ c^{+} }\right) }\right) \setminus \left\{ { f \left({ c }\right) } }\right)$ is infinite.