Difference between revisions of "2018 AMC 12B Problems/Problem 5"

Problem

How many subsets of $\{2,3,4,5,6,7,8,9\}$ contain at least one prime number?

$\textbf{(A) } 128 \qquad \textbf{(B) } 192 \qquad \textbf{(C) } 224 \qquad \textbf{(D) } 240 \qquad \textbf{(E) } 256$

Solution 1

Since an element of a subset is either in or out, the total number of subsets of the $8$-element set is $2^8 = 256$. However, since we are only concerned about the subsets with at least $1$ prime in it, we can use complementary counting to count the subsets without a prime and subtract that from the total. Because there are $4$ non-primes, there are $2^8 -2^4 = \boxed{\textbf{(D) } 240}$ subsets with at least $1$ prime.

Solution 2

We can construct our subset by choosing which primes are included and which composites are included. There are $2^4-1$ ways to select the primes (total subsets minus the empty set) and $2^4$ ways to select the composites. Thus, there are $15\cdot16=\boxed{\textbf{(D) } 240}$ ways to choose a subset of the eight numbers.

Solution 3

We complement count. We know that we have $2^8$ subsets in all, including the empty subset. We subtract 1 from the total, so we have $2^8-1$. We also subtract $\dbinom{4}{1},\dbinom{4}{2},\dbinom{4}{3}$, and $\dbinom{4}{4}$, because those are the subsets that do not include a prime number. We have four subsets that do not have a prime number and include one composite number, six subsets that have two composite numbers and no primes, four subsets that include three composite numbers and no prime numbers, and finally one subset with four composite numbers and no prime numbers. We have $2^8-1-4-6-4-1 = 256-1-4-6-4-1 = 250-1-4-4-1 = \boxed{\textbf{(D) }240}$ ways to choose a subset of the eight numbers that include a prime number.

~ pi_is_3.14