Prove that the matrix $A= \begin{pmatrix} 2 & 0 & -2 \\ 0 & 3 & 0 \\ 0 & 0 & 3 \\ \end{pmatrix} $$ $ is diagonalizable and thus find the bases for the eigenspaces and $P^{-1} AP$, where $P$ is the diagonalizaling matrix.
Only thing i know so far is that the eigenvalues are 2 and 3 and 2 has a dimension 1 and 3 has dimension 2. Not sure what to do after.
Clearly (as the matrix is upper triangular) the characteristic polynomial is $\;(t-2)(t-3)^2\;$ , so the matrix is diagonizable iff $\;(t-2)(t-3)\;$ is its minimal polynomial, and indeed:
$$(A-2I)(A-3I)=\begin{pmatrix}0&0&\!\!-2\\0&1&0\\0&0&1\end{pmatrix}\begin{pmatrix}\!\!-1&0&\!\!-2\\0&0&0\\0&0&0\end{pmatrix}=0$$
Added under request: Let us first write
$$\lambda I-A=\begin{pmatrix}\lambda-2&0&2\\0&\lambda-3&0\\0&0&\lambda-3\end{pmatrix}$$
Now, upon substituting $\;\lambda\;$ for the eigenvalues, the above matrix becomes singular and we want, in each case, to find out its kernel or solution space of $\;(\lambda I-A)\vec x=\vec0\;$, which will be the eigenspace corresponding to that eigenvalue, so:
$$\text{For}\;\lambda=2:\;\;\begin{cases}2z=0\\-y=0\\-z=0\end{cases}\implies y=z=0\implies V_2=\text{Span}\,\left\{\,\begin{pmatrix}1\\0\\0\end{pmatrix}\,\right\}$$$${}$$
$$\text{For}\;\lambda=3:\;\;\begin{cases}x+2z=0\end{cases}\implies x=-2z\implies V_3=\text{Span}\,\left\{\,\begin{pmatrix}0\\1\\0\end{pmatrix}\;,\;\;\begin{pmatrix}\!\!-2\\0\\1\end{pmatrix}\,\right\}$$