The correct option is
C x3+3x2-3x+9
Let (x+2)(ax3+bx2+cx+d)=x4+5x3+3x2+3x+18 ax4+(b+2a)x3+(c+2b)x2+(2c+d)x2+2d=x2+5x3+3x2+3x+18
Comparing coefficients of same powers
a=1
b+2a=5
c+2b=3
d+2c=3
2d=18
Solving we get
a=1,b=3,c=−3 and d=9
The required expression is x3+3x2−3x+9