Answer: \(a=3\), \(b=-4\).
We start with the main method. Use the binomial theorem to identify only the terms needed, rather than expanding the whole expression.
First expand the terms needed from \((2+ax)^5\):
\((2+ax)^5=32+80ax+80a^2x^2+\cdots.\)
Now multiply by \((1+bx)\):
\((2+ax)^5(1+bx)=(32+80ax+80a^2x^2+\cdots)(1+bx).\)
The coefficient of \(x\) is
\(80a+32b.\)
Since the given coefficient of \(x\) is \(112\),
\(80a+32b=112.\)
Divide by \(16\):
\(5a+2b=7.\)
The coefficient of \(x^2\) is
\(80a^2+80ab.\)
Since the given coefficient of \(x^2\) is \(-240\),
\(80a^2+80ab=-240.\)
Divide by \(80\):
\(a^2+ab=-3.\)
From \(5a+2b=7\),
\(b=\frac{7-5a}{2}.\)
Substitute this into \(a^2+ab=-3\):
\(a^2+a\left(\frac{7-5a}{2}\right)=-3.\)
Multiply by \(2\):
\(2a^2+7a-5a^2=-6.\)
So
\(3a^2-7a-6=0.\)
Factorising,
\((3a+2)(a-3)=0.\)
Since \(a\) is an integer,
\(a=3.\)
Then
\(5(3)+2b=7,\)
so
\(b=-4.\)
This completes the solution and gives the required result.