Find $E(e^{-\Lambda}|X=1)$ where $\Lambda\sim Exp(1)$ and $P(X=x)=\frac{\lambda^xe^{-\lambda}}{x!}$. 
Let $X$ have probability mass function
  $$P_\lambda(X=x)=\frac{\lambda^xe^{-\lambda}}{x!},\quad x=0,1,2,\ldots$$
  and suppose that $\lambda$ is a realization of a random variable $\Lambda$ with probability distribution function
  $$f(\lambda)=\begin{cases}e^{-\lambda} &; \lambda>0 \\ 0 &; \lambda\leq 0.\end{cases}$$
  What is
  $$E(e^{-\Lambda}|X=1)?$$

I am unsure how to interpret this question. Usually, we have either two discrete random variables $(X,Y)$, or two continuous random variables $(X,Y)$ and I know some techniques to find the conditional expectation $E(X|Y=y)$. But how to do it in general when, as in this case, the random variables are not of the same type?
 A: Ah, these problems are fun. This is a bit of an intro problem to Bayesian methodology. First of all, you need to find the probability density function of $\Lambda \mid X = 1$. By Bayes' Theorem, this is given by
$$\pi_{\Lambda \mid X}(\lambda \mid x = 1) = \dfrac{f_{X \mid \Lambda}(1 \mid \lambda)\pi(\lambda)}{\int\limits_{0}^{\infty}f_{X \mid \Lambda}(1 \mid \lambda)\pi(\lambda)\text{ d}\lambda}\text{,}$$
where $\pi$ is the probability density function of your "prior" random variable (i.e., a parameter which is varying - in this case, your $\lambda$. So $\pi(\lambda) = f(\lambda)$ in the context of your problem).
Now $$f_{X \mid \Lambda}(1 \mid \lambda) = P_{\lambda}(X = 1) = \dfrac{\lambda e^{-\lambda}}{1!} = \lambda e^{-\lambda}\text{.}$$
Furthermore, $\pi(\lambda) = e^{-\lambda}$ for $\lambda > 0$, so 
$$f_{X \mid \Lambda}(1 \mid \lambda)\pi(\lambda ) = \lambda e^{-2\lambda}\text{, } \lambda > 0\text{.}$$
So, in this case,
$$\pi_{\Lambda \mid X}(\lambda \mid x = 1) = \dfrac{f_{X \mid \Lambda}(1 \mid \lambda)\pi(\lambda)}{\int\limits_{0}^{\infty}f_{X \mid \Lambda}(1 \mid \lambda)\pi(\lambda)\text{ d}\lambda} = c\lambda e^{-2\lambda}\text{, }\lambda > 0$$
where $c = \dfrac{1}{\text{that integral}}$ is just some constant [note that the parameter of interest here is $\lambda$!].
Recall that one possible parametrization of the Gamma density function is
$$f(x) = \dfrac{\beta^{\alpha}}{\Gamma(\alpha)}x^{\alpha - 1}e^{-\beta x}\text{, }x \geq 0\text{, } \alpha, \beta > 0\text{.}$$
Because of the similar form (and identical support, i.e., $\Lambda > 0$ and $X > 0$), we can infer that $\Lambda \mid X = 1$ is Gamma distributed with $\alpha = 2$, $\beta = 2$. Furthermore,
$$\mathbb{E}[e^{-\Lambda} \mid X = 1] = \mathbb{E}[e^{(-1)\Lambda} \mid X = 1] = M_{\Lambda \mid X = 1}(-1)$$
where $M_{\Lambda \mid X = 1}$ is the moment-generating function of $\Lambda \mid X = 1$, which is 
$$M_{\Lambda \mid X = 1}(t) = \left(\dfrac{\beta}{\beta - t}\right)^{\alpha}\text{, } t < \beta\text{,}$$
or in this case,
$$M_{\Lambda \mid X = 1}(-1) = \left[\dfrac{2}{2-(-1)}\right]^{2} = \left(\dfrac{2}{3}\right)^{2} = \dfrac{4}{9}\text{.}$$
Of course, you could do all of the integration involved in this problem... but I will leave that up to you if you need it.
