Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. a) G 1 is a context-free grammar with start symbol S 1 , and no other nonterminals whose name begins with S. Similarly, G

1. a)

G1 is a context-free grammar with start symbol S1, and no other nonterminals whose name begins with "S." Similarly, G2 is a context-free grammar with start symbol S2, and no other nonterminals whose name begins with "S." S1 and S2 appear on the right side of no productions. Also, no nonterminal appears in both G1 and G2.

We wish to combine the symbols and productions of G1 and G2 to form a new grammar G, whose language is the concatenation of the languages of G1 and G2. The start symbol of G will be S. All productions and symbols of G1 and G2 will be symbols and productions of G. Which of the following sets of productions, added to those of G, is guaranteed to make L(G) be L(G1)L(G2)?

a) S S1S3, S3 S2 |

b) S S1S3S2, S3

c) S S1S1, S1 S2

d) S S1.S2

-

1. b)

Let L be the language of the grammar:

 S  AB A  aAb | aA |  B  bBa | c 

The operation max(L) returns those strings in L that are not a proper prefix of any other string in L. Determine the language max(L) and identify in the list below the one string that is in max(L).

a) aabbbbcaa

b) abbca

c) abbcaa

d) aaaaabc

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database In Depth Relational Theory For Practitioners

Authors: C.J. Date

1st Edition

0596100124, 978-0596100124

More Books

Students also viewed these Databases questions

Question

What is DDL?

Answered: 1 week ago