Subset Sum Divisible
1. **Problem statement:** Given $n$ consecutive integers $m, m+1, m+2, \ldots, m+n-1$, prove that there exists a non-empty subset of these integers whose sum is divisible by the sum of the first $n$ natural numbers, i.e., divisible by $$S = 1 + 2 + \cdots + n = \frac{n(n+1)}{2}.$$\n\n2. **Key idea:** We want to find a subset of the given integers whose sum is divisible by $S$. This is a classic application of the pigeonhole principle and modular arithmetic.\n\n3. **Step 1: Define partial sums.** Consider the partial sums $$P_k = \sum_{i=0}^{k} (m+i) = (k+1)m + \frac{k(k+1)}{2}$$ for $k=0,1,\ldots,n-1$. These represent sums of the first $k+1$ integers in the sequence.\n\n4. **Step 2: Consider these sums modulo $S$.** We look at $$P_k \bmod S$$ for $k=0,1,\ldots,n-1$. There are $n$ such sums and $S = \frac{n(n+1)}{2}$ possible residues modulo $S$.\n\n5. **Step 3: Apply the pigeonhole principle.** Since there are $n$ sums $P_0, P_1, \ldots, P_{n-1}$ but only $S$ possible residues, and $S > n$ for $n>1$, we consider two cases:\n- If any $P_k \equiv 0 \pmod{S}$, then the subset $\{m, m+1, \ldots, m+k\}$ sums to a multiple of $S$, and we are done.\n- Otherwise, all $P_k$ are nonzero modulo $S$. Since there are $n$ sums and $S$ residues, and $S > n$, this does not guarantee a collision by pigeonhole principle alone. But we can consider the differences of these sums.\n\n6. **Step 4: Look for equal residues among the $P_k$.** If there exist indices $0 \leq i < j \leq n-1$ such that $$P_i \equiv P_j \pmod{S},$$ then subtracting these sums gives $$P_j - P_i = \sum_{k=i+1}^j (m+k) \equiv 0 \pmod{S}.$$ This means the subset $\{m+i+1, m+i+2, \ldots, m+j\}$ sums to a multiple of $S$.\n\n7. **Step 5: Counting residues.** There are $n$ sums $P_0, P_1, \ldots, P_{n-1}$ but only $S = \frac{n(n+1)}{2}$ residues modulo $S$. Since $S > n$, it is possible that all $P_k$ are distinct modulo $S$ and none is zero. However, the key insight is that the sums $P_k$ are distinct modulo $S$ but the number of sums is $n$, which is less than $S$.\n\n8. **Step 6: Use the pigeonhole principle on the $n+1$ sums including $P_{-1} = 0$.** Define $P_{-1} = 0$ (sum of zero elements). Now consider the $n+1$ sums $$P_{-1}, P_0, P_1, \ldots, P_{n-1}$$ modulo $S$. There are $n+1$ sums but only $S$ residues. Since $S = \frac{n(n+1)}{2} \geq n+1$ for all $n \geq 1$, by pigeonhole principle, either one of these sums is congruent to zero modulo $S$ or two of them are congruent modulo $S$.\n\n9. **Step 7: Conclusion.** If any $P_k \equiv 0 \pmod{S}$, the subset $\{m, \ldots, m+k\}$ sums to a multiple of $S$. Otherwise, if $P_i \equiv P_j \pmod{S}$ for some $i < j$, then the subset $\{m+i+1, \ldots, m+j\}$ sums to a multiple of $S$. Thus, in all cases, there exists a non-empty subset of the $n$ consecutive integers whose sum is divisible by $S = \frac{n(n+1)}{2}$.