TITLE: Chameleons Riddle
QUESTION [6 upvotes]: There are 10 red, 11 blue, 12 green chameleons. Sometimes, two
  chameleons meet. If they are the same color, nothing happens. If they
  are different colors, they will both change to the third color. Can
  all chameleons ever be the same color?

Doesn't seem like it is possible but not quite sure how to prove it. Seems like it might have something to do with modular arithmetic.

REPLY [2 votes]: Here is a more mechanical, far less elegant strategy, which ended up being the same as above. I realize that one is looking for invariants, but always have a hard time spotting them. The following technique may provide some solution structure who share my difficulty...
Let $A = \begin{bmatrix} 2 & -1 & -1 \\ -1 & 2 & -1 \\ -1 & -1 & 2\end{bmatrix}$. I look for 'neat' eigenvalue/left eigenvector pairs, and find $v^T=(1,-1,0)$ corresponding to eigenvalue $3$. The 'system' we have is $x_{x+1} = x_n + u_n$, where at each $n$, $u_n$ is one of the three columns of $A$, and $x_n = (r_n, g_n, b_n)^T$ represents the number of each color at time $n$. The solution is $x_n = x_0+u_0+...+u_{n-1}$.
Now I look at $v^T x_n$, and notice that $v^T x_n \pmod 3 = v^T x_0 \pmod 3 = 1$. However, $v^T (33,0,0) = 0 \pmod 3$, and similarly for the other extreme distributions. Hence we can never reach these states.