Lie algebra $\mathfrak{g}$ is perfect if and only if $\mathfrak{g}=[\mathfrak{g},\mathfrak{g}]$.
And we know semisimple Lie algebra must satisfy the $\mathfrak{g}=[\mathfrak{g},\mathfrak{g}]$ then it's perfect.
What is the example of perfect Lie algebra but not semisimple? And what's the sufficient and necessary condition for a perfect Lie algebra to be semisimple Lie algebra?