I'm studying for my combinatorics exam and I'm not quite convinced about this problem:
How many pairs of distinct integers from $1, 2, 3, ..., 60$ are there whose sum of integers is divisible by $3$?
The way I solved it is, I divided the integers into $3$ groups:
$0 \bmod 3, 1 \bmod 3, 2 \bmod 3$ (0m3,1m3,2m3 for future references).
Each group includes $20$ integers, and from there I sorted out all the possible combinations.
It's a sum of two integers, so possible combinations are:
(0m3,0m3),(1m3,1m3),(2m3,2m3),(0m3,1m3),(0m3,2m3),(1m3,2m3).
If two integers are from the same group, then it's $C(20,2)$, and if they are not it's $20^2$. Since there are 3 cases for each group, the answer would be:
$3\cdot C(20,2) + 3\cdot (20^2)$
It turns out that was not the answer. What am I missing here?
The problem with your solution is that your cases (1m3,1m3), (2m3,2m3), (0m3,1m3), and (0m3,2m3) don't work. The counterexamples to each cases are actually all numbers that fit the criteria, but here are some specifics so you can see for yourself: (4,4), (5,5), (3,4), and (3,5).
Now the remaining cases that work are (0m3, 0m3) and (1m3, 2m3). The first case has $\binom{20}{2}$ that work. The second case has $20^2$ cases that work.