Differentiate \left(x^{2}-5 x+8\right)\left(x^{3}+7 x+9\right) in three ways mentioned below: (i) by using product rule. (ii) by expanding the product to obtain a single polynomial.