Continuous extension of a real function defined on an open interval Let $I\subset\mathbb{R}$ be a compact interval and let $J$ denote its interior.
Consider $f:J\to\mathbb{R}$ being continuous.


*

*Under which conditions does the following statement hold?
$$
\text{There exists a continuous extension $g:I\to\mathbb{R}$ of $f$.}\tag{A}
$$

*Is boundedness of $f$ sufficient for (A)?


Call $I = [a, b]$ with $-\infty < a < b < \infty$. Such an extension exists if and only if both $\lim_{x\to a^+} f(x)$ and $\lim_{x\to b^-} f(x)$ exist, and in fact these values become the values of the extension. (The proof is left as a simple exercise.) With this in mind, boundedness is not sufficient due to previously mentioned functions, such as $\sin\left(\frac{1}{x}\right)$ on $(0, 1)$.
