TITLE: Space of bounded continuous functions is complete
QUESTION [77 upvotes]: I have lecture notes with the claim $(C_b(X), \|\cdot\|_\infty)$, the space of bounded continuous functions with the sup norm is complete.
The lecturer then proved two things, (i) that $f(x) = \lim f_n (x)$ is bounded and (ii) that $\lim f_n \in \mathbb{R}$.
I don't understand why it's not enough that $f$ is bounded. I think the limit of a sequence of continuous functions is continuous and then if $f$ is bounded, it's in $C_b(X)$. So what is this $\lim f_n \in \mathbb{R}$ about? Many thanks for your help.

REPLY [3 votes]: Several people have already posted a proof of the fact that $(C_b(X),||.||_\infty)$ is complete. In my answer I will show a nice application of this fact.


Let $C_0(\Bbb{R})$ denote the space of all continuous functions from $\Bbb{R}$ to $\Bbb{R}$ such that for any $f(x) \in C_0(\Bbb{R})$, we have $\lim_{x \rightarrow \infty} f(x) = 0$ and $\lim_{x \rightarrow -\infty} f(x) = 0$. Then $(C_0(\Bbb{R}),||.||_\infty)$ is complete.


Now I claim that any $f(x)$ in this space is bounded. By the condition concerning the behaviour of $f$ at $\pm \infty$, we immediately deduce that there is $M,N \in \Bbb{R}$ such that for all $x > M$, $|f(x)| < C_1$ for some $C_1$ and for all $x < N$, $|f(x) | < C_2$ for some $C_2$. Now the interval $[N,M]$ is compact and so by the extreme value theorem, there is $C_3$ such that $|f(x)|<C_3$ for all $x \in [N,M]$.
Taking $C = \max\{C_1,C_2,C_3\}$ shows that $f$ is bounded on $\Bbb{R}$ with respect to the Euclidean metric and hence bounded with respect to the sup metric $||.||$. One can show that $C_0(\Bbb{R})$ is a closed subspace of $C_b(X)$ and so by your result, it follows that $C_0(\Bbb{R})$ with the sup norm is complete.