AMC 10 Step by Step

2020 AMC 10A Problem 11

P11-15~5 minPrint

What is the median of the following list of 40404040 numbers ?? 1,2,3,…,2020,12,22,32,…,202021, 2, 3, \ldots, 2020, 1^2, 2^2, 3^2, \ldots, 2020^2

Log in to save your progress.
Show solution without answering

Key insight

With 4040 numbers the median is halfway between the 2020th and 2021st. The squares 1, 4, ..., 1936 (44 of them) squeeze in below, pushing the middle down by 44.

Solution

There are 40404040 numbers, an even count, so the median is the average of the 20202020th and 20212021st smallest. The job is to find those two numbers.

  1. Without the squares. The list 1,2,…,20201, 2, \ldots, 2020 alone would have 20202020 as its 20202020th number.
  2. The squares that get in the way. Some squares are small and slip in among the numbers below 20202020. Which ones? 442=193644^2 = 1936 and 452=202545^2 = 2025. So the squares 12,22,…,4421^2, 2^2, \ldots, 44^2 are all at most 19361936: that is 4444 small squares. Every other square is at least 20252025.
  3. Count up to a number mm between 19361936 and 20202020. The numbers in the list that are at most mm are the ordinary numbers 1,2,…,m1, 2, \ldots, m (that is mm of them) plus the 4444 small squares. That is m+44m + 44 numbers.
  4. We want this count to be 20202020: m+44=2020m + 44 = 2020 gives m=1976m = 1976. So exactly 20202020 numbers are at most 19761976, and the biggest of them is 19761976. That makes 19761976 the 20202020th number.
  5. The next number is 19771977. It is not a square, so it appears only once, and it is the 20212021st.
  6. The median is 1976+19772=1976.5\frac{1976 + 1977}{2} = 1976.5.

The answer is (C) 1976.5\boxed{\textbf{(C)}\ 1976.5}.

Why this works

To find the number in a given position of a sorted list, count how many entries are at or below a guess, and adjust the guess until the count is right. Here the 4444 small squares crowd in at the bottom, so everything moves 4444 places down compared with the plain list 11 to 20202020.

Concise solution

A shorter write-up, the way contest solutions are usually written. It may take a different route from the solution above.

With 40404040 entries, the median is the average of the 20202020th and 20212021st smallest.

For an integer m≤2020m \le 2020, the entries that are at most mm are the integers 1,…,m1, \dots, m together with the perfect squares up to mm, namely ⌊m⌋\lfloor \sqrt{m} \rfloor of them. Since 442=1936≤2020<2025=45244^2 = 1936 \le 2020 < 2025 = 45^2, for 1936≤m≤20201936 \le m \le 2020 this count is m+44m + 44.

We want m+44=2020m + 44 = 2020, so m=1976m = 1976. Thus exactly 20202020 entries are ≤1976\le 1976, and the 20202020th smallest entry is 19761976 itself. The next entry is 19771977 (not a square, so it appears once), which is the 20212021st.

Median =1976+19772=1976.5= \frac{1976 + 1977}{2} = 1976.5.

The answer is (C) 1976.5\boxed{\textbf{(C)}\ 1976.5}.

Review in the AoPS books

Similar problems

Problem © Mathematical Association of America (MAA), American Mathematics Competitions. Reproduced for non-commercial educational use. Solution and commentary are original to this site.