The title of this question isn't exactly a complete description, but couldn't come up with a better one-liner
Given the following two theorems, I am trying to prove that Theorem (1) implies Theorem (2):
Theorem (1): Let $f \in L^2(-\pi, \pi).$ Given $\epsilon > 0$, there exists a step function $\phi$ on $[-\pi,\pi]$ such that $||f(x)- \phi(x)||_2 < \epsilon$
Theorem (2): Let $f \in L^2(-\pi, \pi).$ Given $\epsilon > 0$, there exists a continuous function $\psi$ on $[-\pi,\pi]$ such that $||f(x)- \psi(x)||_2 < \epsilon$
Given an interval $I_k=[a_k, b_k) \subset [-\pi, \pi]$ $(a_k<b_k)$, we define $k(x):=d(x,I_k)=\inf\{d(x,y):y \in I_k \}$. For each $n \in \mathbb{N}$ we define $$g_{k,n}(x):=\frac{1}{1+nk(x)} .$$ Notice that for each $n \in \mathbb{N}$ we have $g_{k,n}$ is a continuous function, and $g_{k,n}(x)=1$ whenever $x \in \bar{I_k}=[a_k, b_k]$. If $x \notin \bar{I_k}$, then $k(x)>0$ and so $\lim_{n \to \infty} g_{k,n}(x)=0$. In other words, $g_{k,n} \to \chi_{\bar{I_k}}$ pointwise. Since $(\chi_{I_k}-g_{k,n} )^2 \leq \chi_{I_k}^2$ (the characteristic function of $I_k$), we have that $\lim_{n \to \infty} \| \chi_{I_k}-g_{k,n}\|_2=0$.
Now notice that the step function $\phi$ is a finite linear combination of such characteristic functions. Moreover, a finite linear combination of continuous functions is a continuous function.