`a)x^3+2x^2+x=x(x^2+2x+1)=x(x+1)^2`
`b)xy+y^2-x-y=y(x+y)-(x+y)=(x+y)(y-1)`
`c)x^2-y^2-2x-2y=(x-y)(x+y)-2(x+y)=(x+y)(x-y-2)`
`d)a^2+4a-12=a^2+4a+4-16=(a+2)^2-16=(a+2-4)(a+2+4)=(a-2)(a+6)`
\(a,=x\left(x^2+2x+1\right)\\ =x\left(x+1\right)^2\\ b,=y\left(x+y\right)-\left(x+y\right)=\left(y-1\right)\left(x+y\right)\\ c,=\left(x-y\right)\left(x+y\right)-2\left(x+y\right)\\ =\left(x+y\right)\left(x-y-2\right)\\ d,=a^2+4a+4+9\\ =\left(a+2\right)^2+9\)