Suppose $g$ is an integrable function supported on $[0,1]$, s.t. for all $n \in \mathbb{N} \cup \{0\}, \int x^n g(x) dx = 0$. Prove that $g = 0$ a.e. wrt. Lebesgue measure.
To do this, my attempt was to approximate the characteristic function of an interval by polynomials, as follows:
i) Firstly, we have that $C([0,1])$ is dense in $(L([0,1]),||\cdot||_{1})$. We also have that polynomials in $[0,1]$, call it $\mathbb{R}[x]$, is dense in $(C([0,1])$ wrt. the $\sup$ norm. Hence, given an interval $I$, let $f$ be approximating continuous function to $\chi_I$, such that $||f-\chi_I|| \approx 0$ (we specify the degree of closeness later), and let $p$ be approximating polynomial to $f$ in the sup norm (so $||f-p||_{\infty} \approx 0$, the closeness to be specified)
ii) Then, $| \int g\chi_I - g p | \leq |\int g(\chi_I - f)| + |\int g(f - p)| =: (I) + (II)$. Let's bound these terms:
For the latter term, by applying Hölder's: $|\int g(f - p)| \leq ||g||_1 ||f-p||_{\infty} \leq \frac{\epsilon}{2}$ whenever we choose $||f-p||_{\infty} \leq \frac{\epsilon}{2||g||_1}$
For the former term: since $g$ isn't bounded a.e. necessarily, nor is $||f-\chi_I||_{\infty}$ small, we cannot apply Hölder's. Intuitively though, $g$ is bounded on most of $[0,1]$ (by Markov's), where we can apply Hölder's, and its integral on the remainder is small (by absolute continuity of its integral), where we can use the fact that $||\chi_I - f ||_{\infty} \leq 1 + ||f||_{\infty} < \infty$ since $f$ is continuous on compact set, so bounded.
Formalizing this: as $g$ is integrable, $\forall \eta > 0$, $\exists \delta > 0$, such that $\int_A |g| < \eta$ when $m(A) < \delta$. Choose $\delta_{\epsilon}$ for $\eta = \epsilon$.
Now, by Markov's inequality, $m(|g| \geq t) \leq \frac{||g||_1}{t}$, so choosing $t \equiv t_{\epsilon} > \frac{||g||_1}{\delta_{\epsilon}}$, we have that $\int_{|g| \geq t_{\epsilon}} |g| \leq \epsilon$.
Finally, $|\int g(\chi_I - f)| = |\int_{|g| < t} g(\chi_I - f)| + |\int_{|g| \geq t} g(\chi_I - f)| \leq t ||\chi_I - f||_{1} + \epsilon ||\chi_I - f||_{\infty} \leq t ||\chi_I - f||_{1} + \epsilon(1+||f||_{\infty})$. Thus, we would like $f$ such that $||\chi_I - f||_{1} \leq \frac{\epsilon}{t_{\epsilon}}$: Moreover, we can choose this $f$ such that $||f||_{\infty} \leq 1$, by redefining $f$ as $f = \min\{f, \frac{f}{|f|} \}$ (which preserves continuity + closeness in $L^1$ norm).
Question: Is this argument valid? Is there an easier way of bounding the former term? I saw this other answer which answers this question more easily by considering sequences (and thus choosing an almost surely converging subsequence + DCT), rather than 'arbitrary approximators', so I know there are easier ways out there, but I was curious if the argument with using arbitrary approximators can be simplified.