How to solve this kind of nonlinear differential equation? I have to solve the following equation
$$ z'-e^z=2$$
where $z=f(x)$, but I can't solve this. Could you please help me ?

Try multiplying by $\mathrm{e}^{-z}$, as this will lead to 
$$
\mathrm{e}^{-z}z’ - 1 = 2\mathrm{e}^{-z}
$$
Or
$$
-(\mathrm{e}^{-z})’ - 1 = 2\mathrm{e}^{-z}
$$
We can then re-write as
$$
-y’ -1 = 2y
$$
With $y=\mathrm{e}^{-z}$. Should be easier to solve.
