Theo bài ra , ta có :
\(\left(x+1\right)\left(x+2\right)\left(x+4\right)\left(x+5\right)=40\)
\(\Leftrightarrow\left(x+1\right)\left(x+5\right)\left(x+2\right)\left(x+4\right)=40\)
\(\Leftrightarrow\left(x^2+6x+5\right)\left(x^2+6x+8\right)=40\)
Đặt x2 + 6x = t , ta có :
\(\left(t+5\right)\left(t+8\right)=40\)
\(\Leftrightarrow t^2+13t+40=40\)
\(\Leftrightarrow t^2+13t=0\)
\(\Leftrightarrow t\left(t+13\right)=0\)
\(\Leftrightarrow\left[{}\begin{matrix}t=0\\t=-13\end{matrix}\right.\)
Thay \(\left[{}\begin{matrix}t=0\\t=-13\end{matrix}\right.\)vào x2 + 6x ta được
\(\left[{}\begin{matrix}x^2+6x=0\\x^2+6x=-13\end{matrix}\right.\)
\(\Leftrightarrow\left[{}\begin{matrix}x\left(x+6\right)=0\\x^2+6x+13=0\end{matrix}\right.\)
\(\Leftrightarrow\left[{}\begin{matrix}x=0\\x=-6\end{matrix}\right.\)(Vì\(x^2+6x+13=x^2+6x+9=\left(x+3\right)^2+4\ge4>0\)
Vậy \(S=\left\{0;-6\right\}\)
Chúc bạn học tốt =))