Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

How many strings of six lowercase letters contain the letters a and b in consecutive positions with a preceding b, with all letters distinct?

Can someone give me a general method for thinking about this problem?

Thank you.

share|improve this question

1 Answer 1

up vote 5 down vote accepted

Think about the following different cases:

ab[][][][]

[]ab[][][]

[][]ab[][]

[][][]ab[]

[][][][]ab

How many possibilities are there for case 1?

Can you see why there are the same number of possibilities for each of the five cases?

If so, take the number of possibilities for case 1 and multiply by 5.

share|improve this answer
    
In the first case, are there 26*25*24*23 possibilities for the remaining positions? –  user1038665 Nov 7 '12 at 4:06
    
I assume the '26' is because you are thinking of the 26 different letters in the alphabet. But one of the requirements is that all letters are distinct... –  Benjamin Dickman Nov 7 '12 at 4:11
1  
Ah, ok, so the four positions have possibilities 24*23*22*21? –  user1038665 Nov 7 '12 at 4:40
    
Yes indeed! Now just remember there are 5 different cases and you can finish the problem off. –  Benjamin Dickman Nov 7 '12 at 6:06

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.