I would like to solve the equation: $2\ln(y) = x$
First way: $$2\ln y = x \Leftrightarrow e^{2\ln y}=e^x \Leftrightarrow y^2=e^x\Rightarrow y= \pm \sqrt{e^x}$$ Second way: $$2\ln y = x \Leftrightarrow \ln y= \frac x2 \Leftrightarrow e^{\ln y}=e^{ \frac x2} \Leftrightarrow y=e^{ \frac x2} \Leftrightarrow y= \sqrt{e^x}$$
Why do we get an extra root in the first solution? Which solution is the correct one?