Question: Find CFG ' s and Regular Grammer that generate these regular languages over the alphabet S = { a , b } : 1 .

Find CFG's and Regular Grammer that generate these regular languages over the alphabet
S={a, b}:
1. The language defined by (aaa + b)*
2. The language defined by (a + b)*(bbb + aaa)(a + b)*
3. All strings without the substring aaa.
4. All strings that end in b and have an even number of b's in total.
5. The set of all strings of odd length.
6. All strings with exactly one a or exactly one b.
7. All strings with an odd number of a's or an even number of b's.
For the following CFG's find regular expressions that define the same language
and describe the language.
8. S--aX bS aIb
X-- aX a
9. S- bS aX b
X-- bX aS a
10. S- aaS abSIbaSlbbSIA
11. S- aB IbA I A
A -- aS
B -- bS
12. S- aB bA
A ---> aB a
B --> bA b
13. S- aS bX a
X-- aX bY a
Y--> aY a
14. S--> aS bXl a
X--- aXI bY bZ a
Y-> aY a
Z---> aZ bW
W --> aW a
15. S- bS aX
X---> bS I aY
Y-raYlbYla lb
16.(i) Starting with the alphabet
S={ab()+*}
find a CFG that generates all regular expressions.
(ii) Is this language regular?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!