# Is GINI limited to binary classifiers or can we use it for multi-class classifiers as well?

I have looked around and have seen GINI being used mostly in the context of binary classifiers. Does GINI make sense only for binary classifiers? Can we extend the definition to multiclass classifiers?

$$G(p) = \sum_{i=1}^{J}{p_i} \sum_{k \neq i}^{J}{p_k} = 1-\sum_{i=1}^{J}{(p_i)^{2}}$$
for the scenario with $J$ classes, each having probability $p_i...p_J$, where $|J|$ can be $>2$.