Let us toss a biased coin that comes up heads with probability p and assume the validity of the Strong Law of Large Numbers as described in Exercise 15.Then, with probability 1,
\frac{s_n}{n}\rightarrow p
as n →∞.If f(x) is a continuous function on the unit interval, then we also have
f\left(\frac{S_n}{n}\right) \rightarrow f(p).
Finally, we could hope that
E\left(f\left(\frac{S_n}{n}\right)\right) \rightarrow E (f(p))=f(p).
Show that, if all this is correct, as in fact it is, we would have proven that any continuous function on the unit interval is a limit of polynomial functions. This is a sketch of a probabilistic proof of an important theorem in mathematics called the Weierstrass approximation theorem.
For x ∈ [0, 1], let us toss a biased coin that comes up heads with probability x. Then
E\left(\frac{f(S_n)}{n} \right)\rightarrow f(x).
But
E\left(\frac{f(S_n)}{n} \right)=\sum\limits_{k=0}^{n}{f\left(\frac{k}{n} \right)\left(\begin{matrix} n \\ k \end{matrix} \right) x^k(1-x)^{n-k} } .
The right side is a polynomial, and the left side tends to f(x). Hence
\sum\limits_{k=0}^{n}{f\left(\frac{k}{n} \right)\left(\begin{matrix} n \\ k \end{matrix} \right) x^k(1-x)^{n-k} } \rightarrow f(x).
This shows that we can obtain obtain any continuous function f(x) on [0,1] as a limit of polynomial functions.