   Chapter 9.3, Problem 22ES ### Discrete Mathematics With Applicat...

5th Edition
EPP + 1 other
ISBN: 9781337694193

#### Solutions

Chapter
Section ### Discrete Mathematics With Applicat...

5th Edition
EPP + 1 other
ISBN: 9781337694193
Textbook Problem
1 views

# Consider strings of length n over the set {a, b, c, d}. a. How many such strings contain at least one pair of adjacent characters that are the same’? b. If a string of length ten over {a, b, c, d} is chosen at random, what is the probability that it contains at least one pair of adjacent characters that are the same?

To determine

(a)

To find:

Strings that contains at least one pair of adjacent characters that are the same.

Explanation

Given information:

A strings of length n over the set {a,b,c,d}.

Calculation:

We are interested in the strings of length n over the set {a,b,c,d}

Let

A = Strings of length n

B = Strings of length n with no adjacent pairs of characters the same

A − B = Strings of length n with an adjacent pairs of characters the same

Strings of length n :

Since the set {a,b,c,d} contains 4 elements, each character of the strings of length n has 4 ways.

First character: 4 ways

Second character: 4 ways ....

nth character: 4 ways

Use the multiplication rule:

N(A)=4×4×...×4n repetitions=4n

Thus there are 4n strings of length n.

Strings of length n with no adjacent pairs of characters the same:

Since the set {a,b,c,d} contains 4 elements, each character of the string of length n has 4 ways

To determine

(b)

To find:

The probability that a string contains at least one pair of adjacent characters that are the same, ifa string of length ten over {a,b,c,d} is chosen at random.

### Still sussing out bartleby?

Check out a sample textbook solution.

See a sample solution

#### The Solution to Your Study Problems

Bartleby provides explanations to thousands of textbook problems written by our experts, many with advanced degrees!

Get Started 