Skip to main content

2008 AIME I Problem 7

Problem 7 of 15IntermediateNumber TheoryCombinatorics

Let SiS_i be the set of all integers nn such that 100i≤n<100(i+1).100i \le n \lt 100(i + 1). For example, S4S_4 is the set {400,401,402,…,499}.\{400, 401, 402, \ldots, 499\}. How many of the sets S0,S_0, S1,S_1, S2,S_2, …,\ldots, S999S_{999} do not contain a perfect square?

Your answer

Integer from 0 to 999
Show solution

Solution

Consecutive squares a2a^2 and (a+1)2(a + 1)^2 differ by 2a+1≤992a + 1 \le 99 for a≤49,a \le 49, so the squares from 121^2 to 502=250050^2 = 2500 never skip a hundred-block: every set S0,S1,…,S25S_0, S_1, \ldots, S_{25} contains a perfect square. For a≥50a \ge 50 the gap 2a+1≥1012a + 1 \ge 101 exceeds 100,100, so each of the sets S26,…,S999S_{26}, \ldots, S_{999} contains at most one square. The largest number involved is 99999,99999, and 3162=99856≤99999<3172.316^2 = 99856 \le 99999 \lt 317^2. So the squares landing in S26,…,S999S_{26}, \ldots, S_{999} are 512,522,…,316251^2, 52^2, \ldots, 316^2 — that is, 266266 squares occupying 266266 distinct sets out of those 974.974. Therefore 974−266=708974 - 266 = 708 sets contain no perfect square.
AoPS wiki

Tagged: perfect square · counting integers in a range

More practice