# Arzela Ascoli Theorem for compactness of a set

Define a metric space $C(K)=\left \{ f: K\rightarrow \mathbb{R} \right\}$ , where $f$ is continuous function on $K.$

Its metric is given by $d(f,g)=\left \| f-g \right \|_u = \sup\left \{ \left | f(x)-g(x) \right | :x\in K\right \}$.

Let $B=\left \{ f\in C([0,1]):f\in C^1 ((0,1)),f(0)=0,\left | f'(x) \right | \leq 1\right \}$.

Show that $B$ is compact subset of $C([0,1])$.

(My attempt) I tried to apply Arzela-Ascoli theorem. If I show $B$ is closed,pointwise bounded and equicontinuous on $[0,1]$, then $B$ is compact. I used Mean Value Theorem to show that $B$ is uniformly bounded and equicontinuous on $[0,1]$. But showing the closeness of $B$ was hard for me.

Let $\left \| f_n-f \right \|_u\rightarrow 0$ for $f_{n}\in B$. Then, $\left \| f \right \|_u\leq \left \| f-f_n \right \|_u+\left \| f_n \right \|_u \leq 1+\epsilon$
for arbitary $\epsilon > 0$. But, I don't know how to connect with $\left | f'(x) \right |\leq 1$ and $f(0)=0$.

It's a good thing that showing $B$ is closed is hard for you, because it's not so. In fact the closure of $B$ is the set of $f$ with $f(0)=0$ and $|f(x)-f(y)|\le|x-y|$; such a a function need not be continuously differentiable.
(Possibly the exercise is simply wrong, or possibly you didn't read it carefully enough; in fact $B$ is precompact, meaning it has compact closure.)
If you let $f(t)=|t-1/2|-1/2$ then $f\notin B$ but you can construct a sequence of functions in $B$ that converge uniformly to $f$ by smoothing out the corner..