I wish to prove that for a continuous function $f$ on a compact subinterval $[a,b]$ of $\mathbb{R}$ and any $\epsilon > 0$, there exists a polynomial $P$ such that
$\sup_{x \in [a,b]} |f(x)-P(x)| < \epsilon$
In the course we have covered the following result: Continuous functions on $\mathbb{T}$ can be uniformly approximated by trigonometric polynomials. I believe this result will be useful in proving the theorem.
Well first I want to assume that $[a,b] = [0,\pi],$ because I can always translate the interval to be $[0,\pi]$. However from here I am unsure how to continue.

