\(\sqrt{9-4\sqrt{5}}+\sqrt{9+4\sqrt{5}}=x^2-2x+4\)
\(\Leftrightarrow\sqrt{\left(2-\sqrt{5}\right)^2}+\sqrt{\left(2+\sqrt{5}\right)^2}=x^2-2x+4\)
\(\Leftrightarrow2-\sqrt{5}+2+\sqrt{5}=x^2-2x+4\)
\(\Leftrightarrow4=x^2-2x+4\)
\(\Leftrightarrow x^2-2x=4-4\)
\(\Leftrightarrow x^2-2x=0\)
\(\Leftrightarrow x\left(x-2\right)=0\)
\(\Leftrightarrow\left[{}\begin{matrix}x=0\\x-2=0\end{matrix}\right.\Leftrightarrow\left[{}\begin{matrix}x=0\\x=2\end{matrix}\right.\)
\(S=\left\{0;2\right\}\)