$\mathbb{E}[e^{Xt}] = \mathbb{E}[\mathbb{E}[e^{Xt}\mid Y]] = \mathbb{E}[M_{X\mid Y}(t)]$? $$\mathbb{E}[e^{Xt}] = \mathbb{E}[\mathbb{E}[e^{Xt}\mid Y]] = \mathbb{E}[M_{X\mid Y}(t)]$$
How do I get the above statement? I don't understand how in the 1st step $e^{Xt}=\mathbb{E}[x^{Xt}\mid Y]$ then in the 2nd $\mathbb{E}[e^{Xt}\mid Y] = M_{X\mid Y}(t)$?

This is from the part (b) of the below question: 

And its provided solution: (see 1st 3 lines)


The first step is what is called the law of Iterated Expecations. Simply put, if $X,Y$ are random variables then, $$\mathbb{E}_X[X] = \mathbb{E}_Y[\mathbb{E}_{X \mid Y}[X \mid Y]]$$ and by definition, $\mathbb{E}_{X \mid Y}[X \mid Y]$ is a function of $Y$ and again by definition $\mathbb{E}_{X \mid Y}[e^{xt}\mid Y]$ is the Moment generating function of the random variable defined by the PDF $f_{X\mid Y}(x\mid y)$.
