How do you find the remainder when x^3+7x^2+2x-40 is divided by x-5?