Question

Let Hn denote the set of strings over the alphabet {A, B, C} with no two...

Let Hn denote the set of strings over the alphabet {A, B, C} with no two consecutive letters the same. Let hn = |Hn|. Determine H1, H2, H3, and then find a recurrence for hn. Solve the recurrence relation you found.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

So we can think as we have already got the set of all strings of length n-1.

So we need to put an extra letter to the n-1 length string to make it of length n

if it is ending with a we can add b or c

if it is ending with b we can add a or c

if it is ending with c we can add a or b

So we will get 2 time the string of length n-1

[a,b,c]

PLEASE UPVOTE

Add a comment
Know the answer?
Add Answer to:
Let Hn denote the set of strings over the alphabet {A, B, C} with no two...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT