Determine a polynomial function with some information about the function I am working through some exercises at the end of a textbook chapter on polynomial functions. Till now the questions have been about providing answers based on a given polynomial function. However, with this particular question I am to work backwards and define the polynomial based on some information about it:

use the information about the graph of a polynomial function to determine the function. Assume the leading coefficient is $1$ or $–1$. There may be more than one correct answer.

The $y$-intercept is $(0, 0)$,  the $x$-intercepts are $(0,0)$, $(2,0)$, and the degree is 3.
End behavior: As $x$ approaches $-\infty$, $y$ approaches $-\infty$, as $x$ approaches $\infty$, $y$ approaches $\infty$.
What I can tell is that since it's an odd degree, the functions will approach $-\infty$ or $+\infty$ either side of $x=0$ but that's already provided in the description.
Tried writing it down as: $y = x(x-2)$ since the root of $(0,0)$ is $0$ (right) and the root of $(2,0)$ is $-2$ (right?).
The provided answer is $x^3-4x^2-4x$.
How can I arrive at this solution with the information provided? Granular baby steps appreciated if possible?
 A: There are two $x$-intercepts, the degree is at least $2$, from the behavior at $x$ approach $-\infty$ and $\infty$, the degree is at least $3$.
If it is cubic, the leading coefficient is $1$.
$$y=x(x-2)(x-c)$$
Since there are only $2$ distinct roots, $c$ is either $0$ or $2$.
The solution provided by the book is obtained by taking $c=2$.
Another alternative solution is $x^2(x-2)$.
A: Ok so the problem mentions two, not three, $x$ intercepts which means that one of the roots of this polynomial will have multiplicity $2$, that is, we'll have either a $x^2$ factor or a $(x-2)^2$ factor in our equation. So you were on the right track with $x(x-2)$, but remember that this is supposed to be a polynomial of degree 3 and the previous is only of degree two. So the answer is either $x^2(x-2)$ or $x(x-2)^2$. So which is it? Well, actually either one is correct. The book does say that there may be more than one correct answer, and they're right: both
$$y=x^2(x-2)$$
And
$$y=x(x-2)^2$$
Are correct and satisfy the required properties (check this), and so is any scalar multiple of each. In fact, there are infinitely many satisfactory polynomials, which is why, in addition to the fact that they didn't provide the answer in factorized form, the solution they give is pretty misleading.
