Skip to main content

2012 AIME II Problem 7

Problem 7 of 15IntermediateCombinatoricsArithmeticProblem-Solving Techniques

Let SS be the increasing sequence of positive integers whose binary representation has exactly 88 ones. Let NN be the 10001000th number in S.S. Find the remainder when NN is divided by 1000.1000.

Your answer

Integer from 0 to 999
Show solution

Solution

There are (128)=495\binom{12}{8} = 495 members of SS below 2122^{12} and (138)=1287\binom{13}{8} = 1287 below 213,2^{13}, so NN has 1313 binary digits, and exactly 1287−1000=2871287 - 1000 = 287 members below 2132^{13} exceed it. The (116)=462\binom{11}{6} = 462 members whose binary representations begin 1111 are the largest ones, so NN begins with 1111 and is the 462−287=175462 - 287 = 175th smallest of them. Among these, (96)=84\binom{9}{6} = 84 begin 1100,1100, the next (85)=56\binom{8}{5} = 56 begin 11010,11010, and the next (74)=35\binom{7}{4} = 35 begin 110110.110110. Since 84+56+35=175,84 + 56 + 35 = 175, the number NN is the largest member beginning 110110,110110, namely 11011011110001101101111000 in binary. Its value is 212+211+29+282^{12} + 2^{11} + 2^9 + 2^8 +26+25+24+23=7032,+ 2^6 + 2^5 + 2^4 + 2^3 = 7032, so the remainder upon division by 10001000 is 32.32.
AoPS wiki

Tagged: number base · combinations · systematic listing

More practice