Combinatorics problem from IMO Past Papers. 2011 balls are numbered from 1 to 2011. You have two colors : red and blue. 
The rule is that, the ball numbered n and the ball numbered $n+3$ must have the same color for any $n$ such that $1\leq n \leq 2008.$   Also, the ball numbered 1971 and the ball numbered 2011 must have different colors. In how many ways can you color the balls?
 A: It's clear that the color of ball #1 will determine the color of balls #4,7,10 etc., and ball #2 will determine #5,8,11 etc., and ball #3 will determine #6,9,12 etc. So we need choose only three colors: one for balls numbered an integer congruent to 1 (mod 3), one for balls numbered an integer congruent to 2, and one for balls numbered an integer divisible by 3.
Furthermore, the choice for divisible-by-3 balls (including 1971) determines the choice for congruent-to-1 balls (including 2011), so we really only have 2 choices.
Then the number of ways is $2^2 = 4$
A: Since any two number that are multiples of $3$ apart have the same color, you can reduce this problem to coloring $\mathbb{Z}_3$, such that the congruence classes associated with $1971$ and $2011$ have different colors.
How many such ways are there to color $\mathbb{Z}_3$? There are $2$ ways to color the class associated with $1971$, which fixes the class associated with $2011$. Now we have a third congruence class, which we may color freely. This gives rise to $2*2=4$ colorings.
