I think the title is correct, but I'm not familiar with this sort of question, so maybe it's off. Anyways, the question is
Find all real-valued $f$ that are continuous on $[0,1]$ and satisfy
$$\int_0^1f(x)x^n\, dx = 0, n = 0,1,2,\ldots$$
My first thought is that any functions that are $0$ on $[0,1]$ would work, but are there any other functions? I've seen this sort of problem before, but I don't know how to approach it.
Thanks.
Standard proof uses Weierstrass approximation theorem : any continuous function defined on closed interval $[a,b]$ can be uniformly approximated by polynomial. Using this, there exists sequence of polynomial $p_{n}(x)$ converges uniformly to $f(x)$ on $[0,1]$. By the assumption, we have $\int_{0}^{1}f(x)p_{n}(x)dx=0$ for all $n$ and uniformly convergence gives $\int_{0}^{1}f(x)^{2}dx=0$. Now we can derive $f\equiv 0$ by continuity of $f$.