\(A=2x^2+y^2-2x+2xy+2y+3=y^2+2y\left(x+1\right)+\left(x+1\right)^2+\left(x^2-4x+4\right)-2=\left(y+x+1\right)^2+\left(x-2\right)^2-2\ge-2\)
\(minA=-2\Leftrightarrow\)\(\left\{{}\begin{matrix}x=2\\y=-3\end{matrix}\right.\)
\(P=x^3+2021xy+y^3\)
\(=\left(x+y\right)^3-3xy\left(x+y\right)+2021xy\)
\(=\left(\dfrac{2021}{3}\right)^3\)
\(=\dfrac{8254655261}{27}\)