\(\left(x-2\right)\left(x^2+2x+4\right)-\left(x-1\right)^3+7\\ =x^3-8-x^3+3x^2-3x+1+7=3x^2-3x\\ \left(7x-3\right)\left(2x+1\right)-\left(5x-2\right)\left(x+4\right)-9x^2+17x\\ =14x^2+x-3-5x^2-18x+8-9x^2+17x=5\\ d,=x\left(x^2-4\right)+x^3+27=x^3-4x+x^3+27=2x^3-4x+27\)