Let 3x2+2xy-y2+7x-5y+k = (3x2+2xy-y2)+(7x-5y)+k = (3x-y) (x+y)+(7x-5y)+k.
=(3x-y+a)(x+y+b)=(3x-y)(x+y)+(a+3b)x-(a-b)y+ab
contrast
a+3b=7 a-b=-5 k=ab
The solution is a=-2 b=3 k=-6.
Then 3X2+2XY-Y2+7X-5Y+K=0, that is, (3x-y-2)(x+y+3)=0, that is, 3x-y-2=0 and x+y+3=0.