Exercise 1806Combinatorics › Pigeonhole principleOlympiadAdded 3 Nov 2026
Coloring integers
#pigeonhole#coloring#multiples
Statement
Show that if integers are colored with colors, some color class contains two integers whose difference is divisible by .
Hint
Residues mod .
Show solutionHide solution
Solution
Residues. There are residues mod , and colors. If each color contains at most one residue, we can assign one residue to each color — possible only if there are exactly integers.
For integers. By pigeonhole, two have the same residue mod , i.e. their difference is divisible by .
Conclusion. With more than integers, two same-color integers have difference divisible by .