\(P=x^2\left(b-c\right)+b^2\left(c-x\right)+c^2\left(x-b\right)\)
\(P=x^2b-x^2c+b^2c-b^2x+c^2\left(x-b\right)\)
\(P=bx\left(x-b\right)-c\left(x-b\right)\left(x+b\right)+c^2\left(x-b\right)\)
\(P=\left(x-b\right)\left(bx-cx-bc+c^2\right)\)
\(P=\left(x-b\right)\left[x\left(b-c\right)-c\left(b-c\right)\right]\)
\(P=\left(x-b\right)\left(b-c\right)\left(x-c\right)\)