Maths Olympiad Prep

Library / /108 of 353

Number theory Difficulty 4.8 AIME Find the answer

How many six-digit multiples of 27 have only 3, 6, or 9 as their digits?

A number or a short expression. Fractions can be typed as 3/2, and spacing doesn't matter.

Solution

Divide by 3. We now want to count the number of six-digit multiples of 9 that only have 1, 2, or 3 as their digits. Due to the divisibility rule for 9, we only need to consider when the digit sum is a multiple of 9. Note that 36=183 \cdot 6=18 is the maximum digit sum. If the sum is 18, the only case is 333333. Otherwise, the digit sum is 9. The possibilities here, up to ordering of the digits, are 111222 and 111123. The first has (63)=20\binom{6}{3}=20 cases, while the second has 65=306 \cdot 5=30. Thus the final answer is 1+20+30=511+20+30=51.

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: Omni-MATH, licensed Apache-2.0. Statement reproduced verbatim; metadata (topic, difficulty) added by this project.