Question: 11. (10 points) Create a ) Create a regular expression, DFA, and Regular Grammar that describes a languages that has an even number of as
11. (10 points) Create a ) Create a regular expression, DFA, and Regular Grammar that describes a languages that has an even number of as and an odd number of bs followed by ayn number of cs or ds, OR a patten of even occurrences of the string `cbad`
12. (8 points) Give an explanation as well as 4 examples of why the follow regex does not work for problem 11.
(aa|bb|aabb |abab| abba | baba |baab |bbaa)*b|
b(aa|bb|aabb |abab| abba | baba |baab |bbaa)*|
(aa|bb|aabb |abab| abba | baba |baab |bbaa)*b(aa|bb|aabb |abab| abba | baba
|baab |bbaa)*
ie evenAB = (aa|bb|aabb |abab| abba | baba |baab |bbaa)*
b(evenAB) | (evenAB)b | evenAB (b) evenAB
13. (8 points) What additions or edits (not using intersection) need to be made to the about to where it would satisfy the problem. If you use code to find the solution, please provide the example.
14. (3 points) Write code for problem 11 to determine if a string matches that problem.
please draw the DFA
Step by Step Solution
There are 3 Steps involved in it
The question seems incomplete The instructions for question 12 request an evaluation of a provided regex and provide examples of why it fails yet ques... View full answer
Get step-by-step solutions from verified subject matter experts
