Could someone please suggest with detailed steps and/or a reference,
1) How to convert the below discrete time summation to continuous time form and write it as an integral?
2) Any methods to solve it?
$$ \sum_{t=0}^{T}\left[\left(K-X_{t}\right)\right]\left(Y_{t}-Y_{t+1}\right) $$
Here, $K$ is a constant. $X$ is a geometric brownian motion. $Y$ is another geometric brownian motion.
Please let me know if anything is not clear.