The correct option is D (x+3)
Let the quadratic polynomial be denoted as P(x).
The polynomial when divided by x+2 gives a remainder of 1. So, from remainder theorom, P(−2)=1.
Similarly, the polynomial when divided by x−1 gives a remainder of 4. So, from remainder theorom, P(1)=4.
Now, if P(x) is divided by the product (x+2)(x−1), the remainder can be at most be a linear function.
We can write P(x)=C(x+2)(x−1)+(Ax+B), where A, B, and C are constants.
Use P(1)=4 and P(−2)=1.
We get two equations: A+B=1 and −2A+B=1.
Solving, we get A=1 and B=3. Hence, the remainder is
Ax+B=x+3