# How to show $\int_{0}^{t} s \mathop{dW_{s}} = tW_{t} - \int_{0}^{t} W_{s} \mathop{ds}$?

I'm new to stochastic integration, and I've been stuck on this exercise. I want to show $$\int_{0}^{t} s \mathop{dW_{s}} = tW_{t} - \int_{0}^{t} W_{s} \mathop{ds}$$

holds, but I don't really know how to do so. My book doesn't have very many examples, so I would really appreciate it if someone could please help me with this problem.

Thanks

Apply Ito's Lemma on $$sW_s$$, i.e. (in it's differential form) write $$\mathrm d(sW_s)=\dots$$
You should see the two terms appear, then by integration between $$0$$ and $$t$$ you have it.
We know: $$W_0=0$$.
\begin{align} & d(tW_t) = W_tdt+tdW_t\\ \Rightarrow & tW_t = \int_0^tW_sds +\int_0^tsdW_s\\ \Rightarrow & \int_0^tsdW_s = tW_t -\int_0^tW_sds \end{align}