$X = \{X(t): t \geq 0\}$ is a Poisson process (with intensity $\lambda$). Independent of $X$, $T$ is a random variable that is exponentially distributed with intensity $\theta$.
I need to find the PMF for $Y=X(T)$ and also Var$[X(T)]$.
There is an example in my book that talks about finding the PMF recursively. I'll denote $p_n=P[X(T)]$. If I let $p_0=e^{-\lambda}$, then supposedly $$p_n=\frac{\lambda}{n}p_{n-1}$$ So $$p_1=\frac{\lambda}{n}e^{-\lambda}$$ $$p_2=\frac{\lambda^2}{n^2}e^{-\lambda}$$ Then, this just becomes $$p_n=\frac{\lambda^n}{n^n}e^{-\lambda}$$
Is that right? I don't understand the first recursive part; I just copied that from a similar example from the book. I don't actually know where that comes from.
There's another example that looks exactly the same but has the answer $$\frac{(\lambda t)^n e^{(-\lambda t)}}{n!}$$
Can someone explain how I should be doing this? Would really appreciate it.