Beruflich Dokumente
Kultur Dokumente
USN
Max. Marks:100
Note: Answer FIVEfull questions, selecting
at least TWO questions from each part.
ci
o
o
I a.
o.
d
E
Cd
o
0)
b.
PART _ A
Write the DFAs for the following languages *"r >: {a, b}
(1) The set of all strings ending with a & b.
(ir) The set of all strings not containing the substring aab.
(iii) Set'of all strings with exactly three consecutive a's.
(10 Marks)
Define NFA" Convert the following NFA to its equivalent DFA. [Refer Fig.Q I (b)] (10 Marks)
9?U
-o
oo
coo
.=N
2 a.
Fie.Q1(b)
Consider the following - NFA:
too
Yai
oq
-O
oo)
=!
ooc
{q}
{r}
{'P }
{p}
{q}
{4}
{'}
*r
(r)
(ii)
b.
-+p
?a:I
a..
{r}
{p}
o,\
-6
d4
'Oc
6r
-F
o.
6tro-
ocv
o..l
9E
ta ti,(.)
c.
!O
5.e
>\ (r
eo0
o=
!t !.)
Xo
o-
-(
3 a.
b.
-i
o
o
z
d
!
1) to an
NFA.
(04 Marks)
(10 Marks)
State and prove pumping lemma for regular languages.
Define distinguishable and indistinguishable states. Minimize the following DFA using table
filling algorithm.
(to Marks)
U<
Gi
Fie.e2(b)
_
(0 + 1). (0 +
r<c
G
F
G
G
I of2
10cs56
4a.
b.
(t) L:{0"1"1n>1}
(ii) L: {String / of a's and b's with equal number of a's and b's }
(06 Marks)
'e.
5a.
b.
DANT
D
_B
PART
Define PDA. Construct PDA that accepts the language L : {ww^ | rv . (a+b). and wR is the
reversal of w ). Write IDs for the string aabbaa.
(10 Marks)
Convert the following CFG to PDA and give the procedure for the same.
S -+ aABB I aAA
A-+aBBia
B-+bBBiA
C-+a
6 a.
(10 Marks)
-+ ABC lBaB
A+aAjBaClaaa
B+bBblalD
(i)
(ii)
b.
C-+CAIAC
D->e
Shat are useless symbois?
Eliminate
A+ablAA
B+aBla
(10 Marks)
Define'a turing machine and explain with neat diagram, the working of a basic turing
machine.
b.
a.
b.
c.
d.
Design a turing machine to accept the set of all palindromes over {a.b}
moves made by turing machine for the string aba.
*.
(06 Marks)
'
, (14
Marks)
(20 Marks)
2 of2