To find the posterior distribution of $\lambda$, we need to use the Bayes' theorem:
$$
P(\lambda | X_1, X_2, \dots, X_n) = \frac{P(X_1, X_2, \dots, X_n | \lambda) \cdot P(\lambda)}{P(X_1, X_2, \dots, X_n)}
$$
Since the prior distribution of $\lambda$ is gamma
Show more…