Solution (source code)

= Solution

For $y\geq0$ and $X\sim U(0,1)$,
$$
\Pr(-\log X\leq y)
=\Pr(X\geq e^{-y})
=1-e^{-y}.
$$
The distribution function is zero for $y<0$, so this is exactly the distribution function of $\operatorname{Exp}(1)$. Therefore
$$
\boxed{-\log X\sim\operatorname{Exp}(1)}.
$$