Unformatted text preview: deterministic machine should be the sets of states of the nondeterministic machine. 4. Give NFAs with the speciﬁed number of states recognizing each of the following languages. (a) The language { w  w ends with 00 } with three states. (b) The language { w  w contains the substring 0101, i.e., w = x 0101 y for some x and y } with ﬁve states. (c) The language { w  w contains an even number of 0s, or exactly two 1s } with six states. (d) The language 0 * 1 * * 0 with three states. 5. Give regular expressions for: (a) All binary strings with exactly two 1’s. (b) All binary strings with a double symbol (contains 00 or 11) somewhere. (c) All binary strings that contain both 00 and 11 as substrings. (d) All binary strings without a double symbol anywhere. 1...
View
Full Document
 Spring '10
 FarzanAzadeh
 Formal language, Regular expression, Contextfree grammar, binary strings

Click to edit the document details