You are on page 1of 2

Question No.

1:

a) Let the language L is defined by the following Regular Expression:

ab*c(a+b)c

Which of the following string (S) is / are part of language L?

1. acac

2. acbbc

3. abcac

4. abcc

Answer: String ‘abcac’ and ‘acac’ are part of string.

b) Let us consider we have a language L, Language of all strings that has exactly 1 triple ''b" defined over
alphabet set ∑ = {a,b}. Construct Regular Expression for language L.

Answer:

The ER may be:

a*(bbb )a*

Question No. 2:

Find the concatenation of the following two FAs. Provide its transition table and transition diagram.

FA1:

FA2:

Answer:
Transition table:

New States

Old States A B

z1-=(x1,y1) (x2,y1) = z2 (x1,y2) = z3

z2 = (x2,y1) (x2,y1) = z2 (x1,y2) = z3

z3=(x1,y2) (x2,y1) = z3 (x1,y3)=z4

z4=(x1,y3) (x2,y3) = z5 (x1,y3) =z4

z5 = (x2,y3) (x2,y3) = z5 (x1,y3) = z4

Process completed because no new state is produced after state z5.


a
a

z1 z2
a
b
z3
b a
z4 b b z5
a

You might also like