It has been shown that given $f \in \mathcal C[0,1]$, we have that if $\int_0^1 x^nf(x)\,dx = 0$ for all $n \in \mathbb N$, then $f = 0$.
I was thinking of generalizing this statement to $L^p$ spaces. For instance, if we have that $f \in L^\infty[0,1]$ instead, and $\int_0^1 x^nf(x)\,dx = 0$ for all $n \in \mathbb N$. Can we say that $f = 0$ a.e on $[0,1]$?
That is, if $f$ is measurable on $[0,1]$, with $\|f\|_\infty = \inf\{a \geq 0 \mid \lambda(|f|^{-1}(a,\infty]) = 0\} < \infty$ given $|f|^{-1}(a,\infty] = \{x \in [0,1] \mid |f(x)| > a\}$, can we show that $f = 0$ for all points in $[0,1]$ except some set $B$ where $\lambda(B) = 0$? In this case, we use $\lambda$ to denote the Lebesgue measure.