Define $f(x)$ as $2x^3-15x^2+36x+1$. Its domain is given to be $[0, 3]$ and range is $[1,29]$. Is it one-one? Is it onto?
I know that a monotonically increasing or decreasing function is one-one.
$$f'(x)= 6x^2-30x+36= 6(x-2)(x-3)$$ This is clearly positive for values of $x$ greater than three and negative for numbers in $(2,3)$. So the function is not one-one.
To find out whether the function is onto I found the maximum and minimum value of the function.
$$f''(x)= 12x-30$$ which is positive for $x=3$ and negative for $x=2$ where there would be a minimum and maximum respectively.
$f(2) = 29$ and $f(3)= 28$. So the value of $f(x)$ should range between $28$ and $29$. And the function is not onto. But clearly, $f(0)$ is equal to $1$.
I am not sure where I have gone wrong. I have checked my calculations multiple times. Is there a conceptual flaw in my solution? Please help me out.

The reason the test seems to fail is that the critical values you are considering, $x = 2,3$, are local extrema, not necessarily global extrema. Remember that the first/second derivative tests can only identify local extrema without additional information. To see that the function is onto in the domain $[0,3]$ note that $f$ is continuous, and that $f(0) = 1$ and $f(2) = 29$. By the Intermediate Value Theorem, then, $f$ is onto the range $[1,29]$.