TITLE: Which of the following sets are dense in $C[0,1]$
QUESTION [6 upvotes]: Which of the following sets are dense in $C[0,1]$ with respect to sup-norm topology?
$1$. {$f$$\in$ $C[0,1]$ : $f$ is a polynomial }
$2$. {$f$$\in$ $C[0,1]$ :$f(0)$=$0$}
$3$. {$f$$\in$ $C[0,1]$ :$f(0)$$\neq$$0$}
$4$. {$f$$\in$$C[0,1]$ :$\int_{0}^{1}f(x)dx$$=$5}
I am thinking to apply Stone-weierstrass theorem but I don't know how to use it properly. Please help!

REPLY [3 votes]: Hint for 2 :
Let, $S=\{f\in C[0,1]:f(0)\not =0\}$.
Then $S=\{f\in C[0,1]:f(0)<0\}\cup \{f\in C[0,1]:f(0)>0\}$.
So, $\overline S=\{f\in C[0,1]:f(0)\le0\}\cup \{f\in C[0,1]:f(0)\ge0\}=C[0,1]$.
So, $S$ is dense in $C[0,1]$.
Again as $S$ is the union of two open sets so it is open subset of $C[0,1]$.
Hence its complement is nowhere dense.
That is, the set $\{f\in C[0,1]:f(0)=0\}$ is nowhere dense.
Similarly option 4 is nowhere dense.