\(x^2+y=y^2+x\Rightarrow x^2-y^2-x+y=0\)
\(\Leftrightarrow\left(x-y\right)\left(x+y\right)-\left(x-y\right)=0\)
\(\Leftrightarrow\left(x-y\right)\left(x+y-1\right)=0\)
\(\Leftrightarrow x+y-1=0\) (do x;y phân biệt nên \(x-y\ne0\))
\(\Rightarrow y=1-x\)
Do đó:
\(A=\dfrac{x^2+\left(1-x\right)^2+x\left(1-x\right)}{x\left(1-x\right)-1}=\dfrac{x^2-x+1}{x-x^2-1}=\dfrac{x^2-x+1}{-\left(x^2-x+1\right)}=-1\)

