This is an interesting problem. The underlying solution is to solve a system of equations.
First we need to define what's a cubic polynomial function :
f(x) =
, where a,b,c,d are constant values.
We assume from the problem that f(-1) = 40, and that the zeros of our unknown function are -6,-5 and -2.
This gives us a system of equation to solve :
![-216a +36b-6c+d=0\\-125a+25b-5c+d=0\\-8a+4b-2c+d=0\\-a+b-c+d = 40\\](https://img.qammunity.org/2022/formulas/mathematics/college/ic60ofr4tdteoqpreg2hpylkjj5owg97fw.png)
Good luck