Question: Suppose that $C([0, 1])$ is the metric space of all continuous real-valued functions on $[0, 1]$, with the metric $d(f, g) := \sup_{x \in [0, 1]}|f(x) - g(x)|$. Let $f \in C([0, 1])$ such that $d(f, 0) \leq 1$. Define
$$g(x) = \int_0^x f(t) dt,$$
where $x \in [0, 1]$. Prove that $g$ is uniformly continuous on $[0, 1]$.
Attempted Answer: Fix $\epsilon > 0$. We must find $\delta > 0$ such that $\forall x, y \in [0, 1]$ we have that $d(g(x), g(y)) < \epsilon$, whenever $|x - y| < \delta$. By abuse of notation, let $x, y \in [0, 1]$. Without loss of generality, assume that $x > y$. Then,
\begin{align*} d(g(x), g(y)) &= \sup_{z \in [0, 1]}\bigg|\int_0^x f(t) dt - \int_0^y f(t) dt \bigg| \\ &= \sup_{z \in [0, 1]}\bigg| \int_y^x f(t) dt \bigg| \\ &= \sup_{z \in [0, 1]}\bigg| g(x) - g(y)\bigg|\dots \end{align*}
Now I am stuck, or just not sure if I approached this problem correctly. Suggestions?
Since $f$ is continous on a compact set, it achieves it maximum and minimum; let $M=\max_{z\in [0,1]} |f(z)|$. For any $x,y\in [0,1],$ $$|g(x)-g(y)|\leq\int\limits_y^x|f(t)\ dt|\leq\max_{z\in [0,1]} |f(z)| |x-y|=M|x-y|.$$ Can you finish it from there?