x^2+y^2-6x+10y+34=x^2-6x+9+y^2+10y+25=(x-3)^2+(y+5)^2=0两个平方相加等于0,则得到(x-3)^2=(y+5)^2=0则x=3;y=-5x+y=-2
配方得(x-3)2+(y+5)2=0所以x=3,y=-5,x+y=-2