Question: Some regular expressions are easy to write; some hard. a. Write a regular expression for strings over {a,b} that end aab b. In class, we
Some regular expressions are easy to write; some hard. a. Write a regular expression for strings over {a,b} that end aab b. In class, we wrote this expression for stings NOT containing the substring aab a* | b*a* | (b*ab*aa*)* The a* is not needed -- can just be dropped. Why? Can you think of a string that should be generated and is not? If so, what? Can you think of a string that this generates which is not legal? If so, what? Can you find a correct expression for string NOT containing aab? If so, what is it?
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
