FLAT Unitwise Imp Questions
FLAT Unitwise Imp Questions
Unit-2
Short answer questions:
1. Define Regular Languages, Pumping Lemma, Context Free Grammars, ambiguous
grammar.
2. Write the applications of pumping lemma for regular languages.
3. List any two applications of regular expression.
4. Write through an intermediate state whose number is not greater than K-1.
5. Write regular expression for denoting language containing empty string.
1. Write a short notes on Chomsky Normal Form and Griebach Normal Form.
2. Show that the following grammar is ambiguous with respect to the string
aaabbabbba.
S aB | bA
A aS| bAA| a
B bS | aBB | b
3. Use the following grammar :
S ABC | BbB
A aA | BaC|aaa
B bBb| a|D
CCA|AC
D ɸ
Eliminate ε-productions.
Eliminate any unit productions in the resulting grammar. Eliminate
any useless symbols in the resulting grammar. Convert the
resulting grammar into Chomsky Normal Form
4. Illustrate the construction of Griebach normal form with an example
5. Show that the following CFG ambiguous.
S iCtS | iCtSeS | a
C b
6. Discuss the Pumping lemma for Context Free Languages concept with
example {anbncn where n>0}
7. Write the procedure to convert CFG to PDA and also convert the following CFG
to PDA.
S B | aAA
A aBB | a
B bBB|A
C a
8. Construct a PDA to accept the language L ={ anbn | n >= 1} by a final state.
Draw the graphical representation of the PDA. Also show the moves made by the
PDA for the string aaabbb
9. Construct NPDA for L = { W W R /W ϵ ( 0 + 1)*}
M = ({q1,q2},{0,1}.{R,B,G},δ,q1,R,ϕ}
10. Write the procedure to convert from the given PDA to a CFG. Convert the following
example.
δ(q0,b,z0)={q0,zz0)
δ(q0, b, z)=(q0,zz)
δ(q0, ϵ ,z0)=(q0,ϵ)
δ(q0,a,z) = (q1,z)
δ(q1,b,z)=(q1,ϵ)
δ(q1,a,z0)=(q0,z0)
11. Convert the following grammar into GNF
A1 A2 A3
A2 A3 A1 /b
A3 A1 A2 /a
UNIT 4
Short answer questions:
1. Write the Turing Machine model, List types of TM.
2. Explain Church’s Hypothesis and the moves in Turing Machine.
3. Define Turing Machine, ID of a Turing Machine, Language of Turing Machine
4. Write the difference between Pushdown Automata and Turing Machine.
5. Define Context sensitive language, multi head Turing Machine, multi dimensional
Turing Machine.
UNIT 5
Short answer questions:
1. Define a)Chomsky hierarchy of languages b)Universal Turing Machine c) LR(0)
grammars d) P,NP problems e) Rice ‘s theorem f) decidability & undecidability
2. Give examples for Undecidable Problems
3. Define a)Turing Machine halting problem b) Turing Reducibility c) PCP.
4. Write a short notes on NP complete , NP hard problems.
5. Explain PCP and MPCP with examples.
6. Explain Turing theorem ,Halting problems, Turing Reducibility.
7. Write a shot notes on post's correspondence problem and check the following is
PCP or not.
I A B
1 11 111
2 100 001
3 111 11
8. Define LR(0) items. Find LR(0) for the following example.
S’ Sc
S SA / A
A aSb/ab
9. Construct LR(0) for
SE
E E*B E E + B
E id