Ta có: (x+a)(x+5) = x2+3x+b
\(\Leftrightarrow\) x2+5x+ax+5a = x2+3x+b
\(\Leftrightarrow\) x(5+a)+5a = 3x+b
\(\Leftrightarrow\left\{{}\begin{matrix}5+a=3\\5a=b\end{matrix}\right.\Leftrightarrow\left\{{}\begin{matrix}a=-2\\b=-10\end{matrix}\right.\)