Beruflich Dokumente
Kultur Dokumente
Tech EXAMINATION
Subject: THEORY OF AUTOMATA AND FORMAL LANGUAGES Code: NCS-402
[Time: 3 Hours] [Total Marks: 100]
SECTION-A
Q.1 Attempt all parts. All parts carry equal marks. Write answer of each part in short. (2 x
10=20)
(a) Define Automata. State its applications.
(b) Design a NFA that accepts any binary string that contains 00 or 11 as substring.
(c) Write a regular expression for the language L = {abnw: n >= 3, w (a + b)+}
(d) Distinguish Moore Machine and Mealy Machine.
(e) Find a CFG that generates the Language L= {an bm / 0nm2n}
(f) Check whether the grammar is ambiguous. S->0A | 1B, A->0AA|1S|1, B->1BB|0S|0
(g) Prove that closure properties of CFL are not closed under complement.
(h) Differentiate DPDA and NDPDA.
(i) How a Turing Machine differs from PDA ?
(j) Find whether the lists M = (abb, aa, aaa) and N = (bba, aaa, aa) have a Post Correspondence
Solution?
SECTION-B
Note: Attempt any 5 questions from this section.
(10 x 5=50)
Q.2 Find a DFA equivalent to M = ( { q0,q1,q2},{a,b}, {q0}, { q2}) where d is given as
States
q0
q1
q2
a
q0, q1
q0
-
b
q2
q1
q0, q1
Q.5 Find the left most and right most derivation corresponding to the tree.
Q.6 Explain different types of acceptance of a PDA.Are they equivalent in sense of language
acceptance? Justify your answer.
Q.7 Convert the following CFG into CNF S ASA | aB, A B | S, B b | .
Q.8 Is L={an bn cn /n>=1} a context free language? Justify Your answer.
Q.9 What is meant by a Turing Machine with two way infinite tape? Give the class of language
for which the TM has both accepting and rejecting configuration? Can this be called a Context
free Language?
SECTION-C
Note: Attempt any 2 questions from this section.
(15 x 2=30)
Q.10. Find the regular expression corresponding to the finite automaton given below using
Ardens theorem.
Q.11 i) Construct a PDA from the following CFG. G = ({S, X}, {a, b}, P, S) where the productions
are :
S XS | , A aXb | Ab | ab
ii) If L is Context free language then prove that there exists PDA M such that L=N(M).
Q.12 i) Design a Turing Machine to accept the language L={0n 1n/n>=1}.
ii) Show that halting problem of Turing Machine is undecidable.
NOTE- IN SECTION B & C YOU CAN MAKE SUB DIVISION (A,B,C.) MAXIMUM 3 .