2. Solve the system of equations

$$
\left\{\begin{array}{l}
x+3 y+3 x y=-1 \\
x^{2} y+3 x y^{2}=-4
\end{array}\right.
$$
Answer: $\left(-3 ;-\frac{1}{3}\right),(-1 ;-1),\left(-1 ; \frac{4}{3}\right),\left(4 ;-\frac{1}{3}\right)$.

Solution. Let's make the substitution $x+3 y=u, x y=w$. Then the system takes the form

$$
\left\{\begin{array} { l } 
{ u + 3 w = - 1 , } \\
{ u w = - 4 }
\end{array} \Leftrightarrow \left\{\begin{array} { l } 
{ u = - 1 - 3 w , } \\
{ - w ( 1 + 3 w ) = - 4 }
\end{array} \Leftrightarrow \left\{\begin{array}{l}
u=-1-3 w \\
3 w^{2}+w-4=0
\end{array}\right.\right.\right.
$$

From the second equation of the last system, we find that $w=1$ (and then $u=-4$) or $w=-\frac{4}{3}$ (and then $u=3$). We return to the original variables.

If $u=3, w=-\frac{4}{3}$, then $\left\{\begin{array}{l}x+3 y=3, \\ x y=-\frac{4}{3}\end{array} \Leftrightarrow\left\{\begin{array}{l}x=3-3 y, \\ y^{2}-y-\frac{4}{9}=0 .\end{array}\right.\right.$

Thus, $y=\frac{4}{3}$ (in which case $x=-1$) or

$y=-\frac{1}{3}$ (in which case $x=4$).

If $u=-4, w=1$, then $\left\{\begin{array}{l}x+3 y=-4, \\ x y=1\end{array} \Leftrightarrow\left\{\begin{array}{l}x=-4-3 y, \\ 3 y^{2}+4 y+1=0 .\end{array}\quad\right.\right.$ Thus, $y=-\frac{1}{3}$ (in which case $x=-3$) or $y=-1$ (in which case $x=-1$).