The problem that I'm trying to solve is this:
Continuous random variable X has $E(X)=a$ and $D(X)=b^2$ and cumulative distribution function (c.d.f.) $F(x)$. Find $E(Z)$ and $D(Z)$ where $Z=-\ln(1-F(X))$
I'm not sure how to start. I was thinking to find the c.d.f. of $Z$ and then the p.d.f., but the c.d.f. is something like this (if I'm not wrong): $F_Z(z)=P(-ln(1-F(X))\leq z)=P(1-F(X)\geq e^{-z})=P(F(X)\leq 1-e^{-z})$. And $1-e^{-z}$ is the c.d.f. of $\operatorname{Exp}(1)$ but I don't know if that is useful.
For any random variable $X$ which has an invertible distribution $F$, which is the case for continuous r.v., $U=F(X)$ is uniform on [0,1], always. Thus, the density of $U$ is $f_U(u) = 1_{(0,1)}(u)$ where $1_A$ is the indicator function over the set $A$. Thus, you can use this and the fact that $Z = Z(U)$ and $Z^2 = Z(U)^2$, paired with $$ E[g(U)] = \int_\mathbb{R} g(u)f_U(u)du = \int_0^1 g(u) du $$ to get the answers that you need. For instance, $$ E[Z(u)] = \int_0^1 -\log(1-u)du $$ which can be solved through integration by parts.