2012 AMC 12B Problem 12

Below is the professionally curated solution for Problem 12 of the 2012 AMC 12B, from LIVE by Po-Shen Loh. You can also try the full timed exam, view all 2012 AMC 12B solutions, or check the answer key.

All of the real AMC 8, AMC 10, AMC 12, and AIME problems in our complete solution collection are used with official legal permission of the Mathematical Association of America (MAA).

Concepts:inclusion-exclusioncombinations

Difficulty rating: 1660

12.

How many sequences of zeros and/or ones of length 2020 have all the zeros consecutive, or all the ones consecutive, or both?

190190

192192

211211

380380

382382

Solution:

Let AA be the sequences in which all zeros are consecutive and BB those in which all ones are consecutive.

For A,A, there is one all-ones sequence, 2020 sequences with exactly one zero, and (202)=190\binom{20}{2}=190 sequences with two or more zeros (choose the first and last zero position). So A=1+20+190=211,|A|=1+20+190=211, and by symmetry B=211.|B|=211.

A sequence in ABA\cap B is a block of zeros followed by a block of ones, or the reverse; there are AB=40|A\cap B|=40 of these.

Therefore AB=211+21140=382.|A\cup B|=211+211-40=382.

Thus, the correct answer is E.

Problem 12 in Other Years