Answer to Question #225251 in Discrete Mathematics for Amir

Question #225251
How many strings of six lowercase letters from the English alphabet contain:
i.The letter a?
ii. The letters a and b?
iii. The letters a and b in consecutive positions with a preceding b, with all the letters distinct?
iv. The letters a and b, where a is somewhere to the left of b in the string, with all the letters
distinct?
1
Expert's answer
2021-08-13T08:18:21-0400

i. The objective is to determine the number of strings of six lowercase letters from English alphabet contain the letter a.

Number of English alphabets is 26.

There are six lower case letters so, the number of possible ways for 6 letters is:

"26 \\times 26 \\times 26 \\times 26 \\times 26 \\times 26 = 26^6"

For the strings that does not contain a there are 25 possible ways.

"25 \\times 25 \\times 25 \\times 25 \\times 25 \\times 25 = 25^6"

The number of possible strings containing a is the total number of strings minus the number of strings that does not contains a.

"26^6 -25^6 = 308915776 -244140625 = 64775151"

Therefore, there are 64775151 number of strings of six lowercase letters from English alphabet contain the letter a.

ii. The objective is to determine the number of strings of six lowercase letters from English alphabet contains the letters a and b.

Number of English alphabets is 26.

There are six lower case letters so, the number of possible ways for 6 letters is:

"26 \\times 26 \\times 26 \\times 26 \\times 26 \\times 26 = 26^6"

For the strings that does not contain a there are 25 possible ways.

"25 \\times 25 \\times 25 \\times 25 \\times 25 \\times 25 = 25^6"

For the strings that does not contain b there are 25 possible ways.

"25 \\times 25 \\times 25 \\times 25 \\times 25 \\times 25 = 25^6"

For the strings that contains neither a nor b, there are 24 possible ways.

"24 \\times 24 \\times 24 \\times 24 \\times 24 \\times 24=24^6"

The possible strings that not containing a or b is:

256+256 -246

The number of possible strings containing a and b is the total number of strings minus the number of strings that does not containing a or b.

"26^6-(25^6+25^6-24^6) \\\\\n\n= 308915776 -(2 \\times 244140625 -191102976) \\\\\n\n= 11737502"

Therefore, there are 11737502 number of strings of six lowercase letters from English alphabet contains the letters a or b.

iii. The objective is to determine the number of strings of six lowercase letters from English alphabet contain the letters a and b in consecutive positions with a preceding b and all the letters are distinct.

As the letters are consecutive, the possible strings are in the form:



Here ab can be in five locations, that is C(5,1) = 5 ways.

The order of the letters is needed, so use a permutation.

As the letters are distinct, select 4 letters from remaining 24 letters.

"n=24 \\\\\n\nr=4 \\\\\n\nP(24,4) = \\frac{24!}{(24-4)!} \\\\\n\n= \\frac{24!}{20!} \\\\\n\n=255024"

Thus, the possible number of strings is "5 \\times 255024 = 1275120"

Therefore, there are 1275120 number of strings of six lowercase letters from English alphabet contain the letters a and b in consecutive positions with a preceding b and all the letters are distinct.

iv. The objective is to determine the number of strings of six lowercase letters from English alphabet contains the letters a and b where a is somewhere to the left of b in the string, with all the letters are distinct.

The order for the letters a and b is needed, so use a permutation.

As two positions are to be selected, so

"r=2 \\\\\n\nn=6 \\\\\n\nP(6,2) = \\frac{6!}{(6-2)!} \\\\\n\n= \\frac{6!}{4!} \\\\\n\n= 30"

Half of the permutations will have a preceding b while the other half will have b preceding a.

"\\frac{30}{2}=15"

The order of the letters is needed, so use a permutation.

As the letters are distinct, select 4 letters from remaining 24 letters.

"n=24 \\\\\n\nr=4 \\\\\n\nP(24,4) = \\frac{24!}{(24-4)!} \\\\\n\n= \\frac{24!}{20!} \\\\\n\n= 255024"

Thus, the possible number of strings is "15 \\times 255024 = 3825360"

Therefore, there are 3825360 number of strings of six lowercase letters from English alphabet contains the letters a and b where a is somewhere to the left of b in the string, with all the letters are distinct.


Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS