Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Let A = {a, b, c, d, e, f, g, h}. Count the number of different strings that mee

ID: 3818673 • Letter: L

Question

Let A = {a, b, c, d, e, f, g, h}. Count the number of different strings that meet each of the criteria. Strings that are five letters, letters can be repeated. Strings that are five letters, letters cannot be repeated. Strings that are five letters, starts with 'a' and ends with 'h', letters cannot be repeated. Strings that are six letters, either starts with the substring 'ab' or ends with the substring 'gh' or both, letters can be repeated. Strings that contain all eight letters exactly once. Strings that contain all eight letters exactly once and contains the substring 'bag'. Strings that contain all eight letters exactly once and the letters 'a' and 'b' must be adjacent to each other such as 'feabcdgh' and 'hgdfbaec'.

Explanation / Answer

a. Strings thar are five letters, letters can be repeated.
As letters can be repeated,
The first position can be filled in 8 different ways.
The second position can also be filled in 8 different ways.
The third position can also be filled in 8 different ways.
The fourth position can also be filled in 8 different ways.
The fifth position can also be filled in 8 different ways.
So, the number of different strings possible are: 8 x 8 x 8 x 8 x 8 = 32768.

b. Strings that are five letters, letters cannot be repeated.
As letters cannot be repeated,
The first position can be filled in 8 different ways.
The second position can be filled in 7 different ways, as one letter is already assigned.
The third position can be filled in 6 different ways, fourth position in 5 different ways,
and fifth position can be filled in 4 different ways.
So, the number of different strings possible are: 8 x 7 x 6 x 5 x 4 = 14560.

c. Strings that are five letters, starts with 'a' and ends with 'h', letters cannot be repeated.
So, first position and last position is readily fixed.
Now, the second position can be filled in 6 different ways.
The third position can be filled in 5 different ways.
The fourth position can be filled in 4 different ways.
So, the number of different strings possible are: 6 x 5 x 4 = 120.

d. Strings that are six letters, either starts with a substring 'ab', or ends with the substring
'gh' or both, letters can be repeated.
So, consider Letters that start with ab. So, in the remaining 4 places, can be filled with
8 characters each.
So, the number of different strings starting with 'ab' are: 8 x 8 x 8 x 8 = 4096.
The same happens with strings ending with 'gh', that are 4096 again.
Strings that are counted twice i.e., that start with ab, and end with gh should be subtracted
once. So, that kind of strings are: 8 x 8 = 64.
So, the answer is: 4096 + 4096 - 64 = 8128.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote