show convergence of sum towards integral -- not Riemann partition but using another convergence $X_1, X_2, ...$ real random variables. $P(X_n=\frac{k}{n}) = \frac{1}{n}$ for $k\leq n \in \mathbb{N}$. Let further $X \overset{d}{=}U_{[0,1]}$.
I showed $X_n \overset{d} \to X$ when $n \to \infty$ (*).
Using this I know want to show: for every continous function $f:[0,1]\to \mathbb{R}$ the following equation holds:
$$\int_0^1 f(x)dx = \lim_{n\to \infty} \frac{1}{n} \sum_{k=1}^n f\left(\frac{k}{n}\right)$$
I do not know how to use (*) to show that, instead of just claiming, that on the right hand side this is the definition of the Riemann-integral as sum of $f\left(\frac{k}{n}\right)$ times the length of the i-th part of the partition $\frac{1}{n}$. So and as $n \to \infty$ this partition converges and get's in any order finer and therefore the right hand side converges against the integral value.
Any ideas how to use (*) here?

Hints: Note that $\int\limits_0^1f(x)\mathrm dx=E[f(X)]$ and that $\frac1n\sum\limits_{k=1}^nf\left(\frac{k}n\right)=E[f(X_n)]$ hence the goal is to prove that $\lim\limits_{n\to\infty}E[f(X_n)]=E[f(X)]$. The context is that $f$ is continuous on $[0,1]$ and that $X_n\to X$ in distribution. Maybe all this rings a bell (it definitely should!).
