\(a,x^2-x-xy-2y^2+2y\)
\(=xy+x^2-x-2y^2-2xy+2y\)
\(=\left(xy-2y^2\right)+\left(x^2-2xy\right)-\left(x-2y\right)\)
\(=y\left(x-2y\right)+x\left(x-2y\right)-\left(x-2y\right)\)
\(=\left(x-2y\right)\left(y+x-1\right)\)
\(b,x^2+4xy+2x+3y^2+6y\)
\(=3y^2+xy+3xy+x^2+6y+2x\)
\(=y\left(3y+x\right)+x\left(3y+x\right)+2\left(3y+x\right)\)
\(=\left(3y+x\right)\left(y+x+2\right)\)
a) \(x^2-x-xy-2y^2+2y\)
\(=x^2-x-xy-y^2-y^2+y+y\)
\(=\left(x^2-y^2\right)-\left(x-y\right)-\left(xy+y^2-y\right)\)
\(=\left(x-y\right)\left(x+y\right)-\left(x-y\right)-y\left(x+y-1\right)\)
\(=\left(x-y\right)\left(x+y-1\right)-y\left(x+y-1\right)\)
\(=\left(x+y-1\right)\left(x-2y\right)\)