Combinatorics & Counting


Answer & solution
Answer: 9, 000, 000 (no official key was published)
The interval 1, …, 300 contains exactly 100 representatives of each residue modulo 3. For each ordered pair (i, j), the required residue of k is uniquely −i−j modulo 3, and precisely 100 values of k realize it. There are 300² ordered pairs, so the total is 300²×100=9, 000, 000. Repetitions and different orderings are permitted because these are triples, not three-element subsets. Equivalently, exactly one third of the 300³ triples have residue sum zero. Both bounds are inclusive.