is there a smart way of doing this besides brute force?
An $n\times n$ matrix $C$ is type $I$ if $C^2=C$ and an $n\times n$ matrix $D$ is type $II$ if $D^2=0_{n}$. Determine if the following matrices are type $I, II,$ or neither: $$A=\begin{bmatrix}2&-2&-4\-1&3&4\1&-2&-3\end{bmatrix}, B=\begin{bmatrix}1&2&5\2&4&10\-1&-2&5\end{bmatrix}$$