How many strings of 9 lowercase letters from the Englishalph
How many strings of 9 lowercase letters from the Englishalphabet (of 26 letters) contain
a) the letter f at least once?
b) the letters a, and x, in that order, with all letters distinct? For example, caebmxc is avalid string, because all letters are distinct, and a, and x appear in order within the string.
Solution
a) There are 26 alphabets
Hence there are 26 lowercase alphabets. If repitition is allowed,
from 9 lowercase letters total no of letters that can be formed = 269
No of strings of lowercase letters with no f = No of 9 strings from the remaining 25 letters
= 259
The remaining letters will be with atleast one string.
Strings of 9 lowercase letters from the Englishalphabet (of 26 letters) contain
the letter f at least once = 269-259
--------------------------------------------------------------
b) Here all letters are distinct.
Also a and x should be in that order.
The remaining 7 letters can be selected from 24 alphabets excluding a and x in
24C7 ways.
In each letter we can insert a in the I place, and x in any of the remaining 8 gaps (including extreme ends)
So no of letters with a in the first place = 8
If a is inserted in the second place, x should be inserted in the remaining 7 gaps (including extreme ends of 6 alphabets) and so on.
End will be ax appearing at the last.
Thus no of possibilities = 8+7+6+...1 = 36 ways.
Total no of letters = 36(24C7)=346104(36)
= 12459744

