Suppose V is a finite-dimensional complex vector space and T : V → V is a linear transformation which satisfies $T^{2} = T$. Prove that for any vector v $\in$ V , the vector T(v) is contained in the eigenspace $E_{1}$ of eigenvalue $1$ and v −T(v) is contained in the eigenspace $E_{0}$ of eigenvalue $0$. Also prove that T is diagonalizable, and compute the dimensions of $E_{0}$ and $E_{1}$ in terms of the rank of T.
From $T^{2}-T=0$, I could get $\lambda=0$ or $\lambda= 1$ but I do not know how to continue.
Hint: If $v\in V$, then $v=\bigl(v-T(v)\bigr)+T(v)$.