Question

Find a regular expression to describe: The set of all strings over the alphabet {a, b,...

  1. Find a regular expression to describe:

The set of all strings over the alphabet {a, b, c, d} that contain exactly one a and exactly one b

So, for example, the following strings are in this language:

  • ab, ba, cccbad, acbd, cabddddd, ddbdddacccc

and the following strings are NOT in this language:

a, ccbc, acbcaaacba, acacac, bcbbbbbca, aca, c, d, b

Homework Answers

Know the answer?
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
Similar Questions
Give a regular expression for the set of all strings on the alphabet {0,1} with no...
Give a regular expression for the set of all strings on the alphabet {0,1} with no runs of length greater than 3(for example, no substrings 0^i or 1^i with i > 3)
Problem 5 Regular Expressions. a) Define a regular expression for all strings of odd length, over...
Problem 5 Regular Expressions. a) Define a regular expression for all strings of odd length, over the alphabet of {0}. b) Define a regular expression for identifiers over the alphabet of {A,B,C,a,b,c,0,1,2,3,4,5,6,7,8,9}, such that an identifier must begin with an alphabetic character and must contain at least one numeric character. c) Try to modify the definition above so that identifiers still begin with an alphabetic character, but after that, it must contain at least one numeric, at least one lower-case...
For each of the following regular expressions, give 2 examples of strings that are in the...
For each of the following regular expressions, give 2 examples of strings that are in the language described by the regular expression, and 2 examples of strings that are not in that language. In all cases the alphabet is {a,b}. ab*ba* (a ∪ ε)b* (a ∪ b)ε*(aa ∪ bb)
For each of the following regular expressions, give 2 examples of strings that are in the...
For each of the following regular expressions, give 2 examples of strings that are in the language described by the regular expression, and 2 examples of strings that are not in that language. In all cases the alphabet is {a, b}. ab*ba* (a ∪ ε)b* (a ∪ b)ε*(aa ∪ bb)
1.2 Which of the following statements is wrong?        a). A set is a subset of itself...
1.2 Which of the following statements is wrong?        a). A set is a subset of itself        b). Emptyset is a subset of any set        c). A set is a subset of its powerset        d). The cardinality of emptyset is 0 1.3. Which of the following statements is correct?        a). A string is a set of symbols from an alphabet        b). The length of the concatenation of two strings can           be the same as one of them        c). The length of...
Which one of the following languages over the alphabet {0,1} is described by the regular expression...
Which one of the following languages over the alphabet {0,1} is described by the regular expression (0+1)* 0 (0+1)* 0 (0+1)* ? a.The set of all strings that begin and end with either 0 or 1 b.The set of all strings containing at most two zeros c.The set of all strings containing at least two zeros. d.The set of all strings containing the substring 00
Give a regular expression for the set of strings over {a, b, c} such that the...
Give a regular expression for the set of strings over {a, b, c} such that the sum of the number of a’s and the number of b’s is equal to 3.
1. Define a deterministic finite automaton over the alphabet {a, b} which accepts the set of...
1. Define a deterministic finite automaton over the alphabet {a, b} which accepts the set of all strings that end with the substring ab or ba.
Write the regular expression for the following sets (4.5) 4.1 All strings over {a,b} that are...
Write the regular expression for the following sets (4.5) 4.1 All strings over {a,b} that are odd in length 4.2 All strings over {a,b} whose length is not a multiple of 3 4.3 All strings over a,b that start with aa and end with bb
Consider the regular expression ? = b(ba U aab)*(b U a*). In lexicographical order (shorter strings...
Consider the regular expression ? = b(ba U aab)*(b U a*). In lexicographical order (shorter strings before longer strings, alphabetical order for strings of the same length), give the 8 shortest strings in the language generated by ?.
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT