Take a test Sign in 中文
← Exercise 402 →
Search
Go to
{{searchResults.length}} {{searchResults.length === 1 ? 'result' : 'results'}} for “{{searchWords}}” No results found for “{{searchWords}}” × back to contents
AIME Contents · by chapter
Basic Counting (90)
---- (44)
Probability (91)

Exercises and their solutions

Exercise 402
Let $S$ be a subset of $\{1,2,3,\ldots,2024\}$ such that no two members of $S$ differ by $5$ or $8$. What is the largest number of elements $S$ can have?
← Back to Problem 402
Solution
  1. In a block of $13$ consecutive numbers, list them as $x, x+5, x+10, x+2, \dots$ (adding $5$ mod $13$): consecutive entries of this cycle of length $13$ differ by $5$ or $8$, so at most $6$ can be chosen.
  2. In any $9$ consecutive numbers, the pairs $(i,i+5)$ give at most $5$.
  3. Since $2024=13\cdot155+9$, $|S|\le 155\cdot6+5=935$.
  4. Taking all $x$ with $x\bmod 13\in\{1,2,4,5,8,11\}$ gives exactly $935$ numbers.
  5. The answer is $\boxed{935}$.
Search Go to Prev      Next

Contact Us

Thanks! Your message has been sent.
By year
1985 (1 problems)
1984 (1 problems)