# How many strings in the letters a, b, and c have length 10 and exactly four a's?

part a) How many strings in the letters a, b, and c have length 10 and exactly four a's?

I did $\binom{10}{4} = 210$ different ways for the strings of length $10$ in part a to be arranged, but I'm confused on the rest.

FIGURED OUT PART A, not part B yet

part b) How many strings in the letters a, b, and c have three a's and at most six letters?

For strings of length $3$ there is only $1$ combo aaa. Then for strings of length of $4$ there are aaa, baaa, caaa, abaa, acaa, aaba, aaca, aaab, aaac so that is $8$, but I'm not sure of the pattern for lengths $5$ and $6$.

So now I have $1$ for length $3$, $8$ for length $4$.

Still having problems with finding lengths $5$ and $6$.

• It would be good to add the question statement in the question itself, and label it as part a).
– user122283
Commented Mar 12, 2014 at 0:33

Hint: for the first part, how many choices are there for each of the remaining six positions? for part b, you use the same logic as for part a. So for six letters, you choose the three places for a's (how many ways), then choose the other three letters (how many ways?)

• wowwww. thanks. 10 choose 4 * 2^6 = 13440. now i'm going to try part b
– Leo
Commented Mar 12, 2014 at 0:44

For part b, the strings can be of the following lengths - $0,1,2,3,4,5$ or $6$. Our requirement is that the required string must contain exactly 3 a's. Therefore, we can rule out strings of length $0,1$ and $2$.

1. For strings of length $3$, as you have already figured out, you can have only $\underline{1}$ string that satisfies the given constraints, that is 'aaa'.
2. For strings of length $4$, imagine four dashes like so _ _ _ _. How many ways can you put a combination of $3$ a's in there? It can be a _ aa or _aaa or aa_a and so on. Name the dashes d1,d2,d3,d4. We are essentially picking a combination of three dashes and adding a's to them. a_aa corresponds to (d1,d2,d3). We want all such combinations. There are simply $\dbinom{4}{3}$ such combinations. And since we choose three spaces, there is one empty space. This can take two possible values, b or c. So, for every combination of dashes, like (d1,d2,d3), we have $2$ choices for the remaining blank. So there are a total of $\dbinom{4}{3} \times 2 = \underline{8}$ choices for strings of length $4$.
3. We can apply the same line of thinking for strings of greater length. For strings of length $5$, the 3 a's can occupy a total of $\dbinom{5}{3}$ positions and the remaining positions have two choices, b or c. Hence, the total number of choices are $\dbinom{5}{3} \times 2^2 = \underline{40}$ choices.
4. Similarly, for strings of length $6$, the answer is $\dbinom{6}{3} \times 2^{3} = \underline{160}$ choices.

Thus, our final answer is $1 + 8 + 40 + 160 = \boxed{209}$ possible strings.