Answer
$(y+1)e^{-y}=-\ln |x| +c$
Work Step by Step
In order to to solve the given differential equation we will have to separate the variables and then integrate.
Here, we have
$\int ye^{-y} dy=\int \dfrac{dx }{x} $
or, $-ye^{-y} +\int e^{-y} dy=\ln |x| +c$
Then, we have $-(y+1)e^{-y}=\ln |x| +c$
Hence, $(y+1)e^{-y}=-\ln |x| +c$