\(A=\left(x^2-2xy+y^2\right)+2\left(x-y\right)+1+x^2+6x+9+1978\)
\(=\left(x-y\right)^2+2\left(x-y\right)+1+\left(x+3\right)^2+1978\)
\(=\left(x-y+1\right)^2+\left(x+3\right)^2+1978\ge1978\)
\(A_{min}=1978\) khi \(\left\{{}\begin{matrix}x=-3\\y=-2\end{matrix}\right.\)