Solving cubic equation x ^ 3-3x ^ 2 + 2 with one variable

Solving cubic equation x ^ 3-3x ^ 2 + 2 with one variable

A:
x^3-3x^2+2
=(x^3-x^2)-2(x^2-1)
=(x-1)x^2-2(x-1)(x+1)
=(x-1)(x^2-2x-2)
So:
x^3-3x^2+2=0
(x-1)(x^2-2x-2)=0
The solution is: x = 1 or x ^ 2-2x + 1 = 3
The solution is: x = 1 or x = 1 + √ 3 or x = 1 - √ 3