Flat Question Papers

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

Course Code : 15CT1119/2015 R-2015 Reg.

No :

GAYATRI VIDYA PARISHAD COLLEGE OF ENGINEERING (AUTONOMOUS)


Madhurawada, Visakhapatnam
Affiliated to JNT University – K, Kakinada
B.Tech. V-Semester Regular Examinations, Oct./Nov. 2017
FORMAL LANGUAGES AND AUTOMATA THEORY
(Common to CSE & IT)

Date : 08-11-2017 Time : 3 Hours Max. Marks : 70


1. Answer ONE Question from each UNIT
2. All parts of a Question must be answered in one place to get valued.
3. All questions carry equal marks.

UNIT-I
1. a) Define DFA, Design a DFA for accepting all the strings with odd number of a’s and even 5 Marks
number of b’s.
b) Define NFA, design NFA for accepting all the strings in L= ambn | m,n>=1 5 Marks
c) Discuss the applications of Finite automata. 4 Marks

2. a) Design NFA for accepting the strings { ab, ba } and then convert it to DFA. 7 Marks
b) Define Mealy Machine; design a Mealy machine to generate output Y for all the strings 7 Marks
ending with 00 or 11 and for all the remaining strings output will be N.

UNIT-II
3. 7 Marks
a) Give the Statement of Pumping lemma on Regular sets, how it is useful?
7 Marks
b) Prove that L= WWR|W € {a,b}* is not regular?

4. a) Design NFA with ε moves for the regular expression (0+1)*00 (0+1)* 7 Marks
b) Prove that L= ap | p is prime is not regular 7 Marks
UNIT-III
5. a) Define Right linear grammar and left linear grammar., write RLG for 00 (0+1)* 7 Marks
b) What is ambiguous grammar? Show that the following grammar is ambiguous 7 Marks
SS + S | S * S| a |b
6. a) Define CFG and write the Context free grammar for generating 8 Marks
i) Equal number of a’s and b’s.
ii) Balanced parenthesis
b) Define CNF and Convert the following CFG to CNF SaSa | bSb | a |b 6 Marks

UNIT-IV
7. a) Discuss the model of Push down automata; give the Mathematical definition of PDA. 4 Marks

b) Design PDA to accept the language L= an c bn | n>=1 Verify whether the string aacbb is 10 Marks
accepted or not

Page 1 of 2
Course Code : 15CT1119/2015 R-2015 Reg. No :

8. a) Discuss on deterministic PDA and Non deterministic PDA. 4 Marks

b) Construct PDA for L= W C WR | W € {a,b}* Verify whether the string abcba is 10 Marks
accepted or not

UNIT-V
9. a) Define Turing Machine and what are the components of Turing Machine? 4 Marks

b) Design a Turing Machine to recognize the Regular language L= am bn | m,n>=1 10 Marks

10. a) Explain Church Hypothesis. 4 Marks

b) Design a Turing Machine to recognize the Context sensitive language L= an bn cn | n>=1 10 Marks

Page 2 of 2

You might also like