$f(x) = \left\{\begin{array}{lcl}-x^3 + 1&\text{if}&x\geq0\\ -x^2+2x&\text{if}&x<0\end{array}\right.$ I want to find the critical points but after differentializing and equalizing to $0$, the $x$ which one is 1 and other is 0. (I think that the point should be the same one?)
What's wrong with it?