Solution to: Colorful Chameleons
Name the number of blue chameleons b, the number of green chameleons g, and the number of purple chameleons p.
With each encounter between two differently colored chameleons, the number of those two color variants decreases by 1, and the number of the other color variant increases by 2. As a result, the difference in the numbers of the first two color variants remains the same, while the differences in the numbers of the first two color variants and the third color variant increase by 3.
For example, if in the initial situation a blue and a green chameleon meet, both change their color to purple. The new numbers of chameleons then become b - 1, g - 1, and p + 2.
The table below provides an overview of all possible encounters between two differently colored chameleons, including the resulting difference in number between the color variants.
Encounter | Resulting number per color variant | Resulting difference in number | ||||
---|---|---|---|---|---|---|
Blue | Green | Purple | Green - Blue | Purple - Green | Purple - Blue | |
Blue and Green | b - 1 | g - 1 | p + 2 | g - b | p - g + 3 | p - b + 3 |
Green and Purple | b + 2 | g - 1 | p - 1 | g - b - 3 | p - g | p - b - 3 |
Blue and Purple | b - 1 | g + 2 | p - 1 | g - b + 3 | p - g - 3 | p - b |
In the given initial situation, there are 13 blue, 15 green, and 17 purple chameleons. We can note the following:
- The difference between the number of green and blue chameleons is g - b = 15 - 13 = 2. This is a multiple of three plus 2, since 2 = 3 × 0 + 2.
- The difference between the number of purple and green chameleons is p - g = 17 - 15 = 2. This is also a multiple of three plus 2.
- The difference between the number of purple and blue chameleons is p - b = 17 - 13 = 4. This is a multiple of three plus 1, since 4 = 3 × 1 + 1.
Now, if we look at the resulting difference in number after an encounter, as shown in the table above, we see that during the encounter between two differently colored chameleons, nothing changes in the mutual differences:
- The difference between the number of green and blue chameleons remains a multiple of three plus 2.
- The difference between the number of purple and green chameleons remains a multiple of three plus 2.
- The difference between the number of purple and blue chameleons remains a multiple of three plus 1.
In the situation where all chameleons have the same color, the difference between any two color variants is a multiple of three (the color variants that no longer occur differ from each other by 0 in number and both differ by 45 in number from the remaining color variant). However, based on the given initial situation, that scenario can never be reached.
Conclusion: It is not possible for all 45 chameleons to be the same color at any given time.
