17. Let the complex number $z$ vary under the condition $|z|=1$, find the maximum and minimum values of $\left|z^{3}-3 z-2\right|$.

Let the complex number $z$ vary under the condition $|z|=1$, find the maximum and minimum values of $\left|z^{3}-3 z-2\right|$.
17. Given $|z^{3}-3 z-2|=| z+1|^{2} \cdot|z-2|$. Let $z=x+i y(x, y \in \mathrm{R})$, then $x^{2}+y^{2}=1(-1 \leqslant x \leqslant 1)$. Hence $|z+1|^{2}=2+2 x,|z-2|=\sqrt{5-4 x}$, thus we have
$$
\left|z^{3}-3 z-2\right| \leqslant \sqrt{\left[\frac{(2+2 x)+(2+2 x)+(5-4 x)}{3}\right]^{3}}=3 \sqrt{3} \text {. }
$$

Equality holds if and only if $2 x+2=5-4 x$, i.e., $x=\frac{1}{2}$. At this point, $y= \pm \frac{\sqrt{3}}{2}$, i.e., $z=\frac{1 \pm \sqrt{3} i}{2}$, achieving the maximum value $3 \sqrt{3}$.
Clearly, when $x=-1$, the minimum value 0 is reached.