Take a test Sign in 中文
← Exercise 914 →
Search
Go to
{{searchResults.length}} {{searchResults.length === 1 ? 'result' : 'results'}} for “{{searchWords}}” No results found for “{{searchWords}}” × back to contents
Contents · by chapter
Digits (38)
Primes (31)
Fractions, Decimals, and the Floor Function (18)
Divisors, GCD, and LCM (36)
Divisibility (59)
Bases (15)
Modular Arithmetic (42)
Integer Equations (27)

Exercises and their solutions

Exercise 914
Bernardo chooses a positive integer $N\le1050$ and writes both its base-$6$ and base-$7$ representations. LeRoy treats the two numbers as base-$10$ integers and adds them to obtain $S$. For how many choices of $N$ is the units digit of $S$ the same as the units digit of $2N$?
← Back to Problem 914
Solution
  1. The units digit of $S$ is the units digit of $a+b$, where $a=N\bmod6$ and $b=N\bmod7$ are the last digits of $N$ in base $6$ and base $7$.
  2. We need $a+b\equiv2N\pmod{10}$, that is, $a+b$ is even and $N\equiv\frac{a+b}2\pmod5$.
  3. Since $6$ is even, $a\equiv N\pmod2$. Writing $N=7q+b$, we get $b\equiv N\pmod 2$ exactly when $q=\lfloor N/7\rfloor$ is even. So $a+b$ is even exactly when $N\bmod42$ lies in $\{0,\dots,6\}\cup\{14,\dots,20\}\cup\{28,\dots,34\}$: $21$ residues.
  4. Each such residue mod $42$ fixes $a$, $b$, and hence $\frac{a+b}2$; by the Chinese remainder theorem (Theorem 103) exactly one residue mod $210$ also satisfies $N\equiv\frac{a+b}2\pmod5$. So $21$ of every $210$ consecutive integers work.
  5. The numbers $1,\dots,1050$ form $5$ full blocks of $210$: $5\cdot21=\boxed{105}$.
Search Go to Prev      Next

Contact Us

Thanks! Your message has been sent.
By year