Solution (source code)

= Solution
{c}

For the independent <random sample>, the <likelihood function> on its support is $L(\theta)=\theta^ne^{-\theta Y}$, where $Y=\sum X_i$. Its <log-likelihood> is $\ell(\theta)=n\log\theta-\theta Y$, with
$$
\ell'(\theta)=n/\theta-Y,\qquad\ell''(\theta)=-n/\theta^2<0.
$$
Almost surely $Y>0$, and the unique stationary point is consequently the unique global maximum:
$$
\boxed{\hat\theta=n/Y.}
$$
The exceptional all-zero sample has probability zero; if $Y=0$ were nevertheless supplied, there would be no finite maximizing rate.