Gujarat Technological University
Gujarat Technological University
___________
n
Σ i2 = n (n+1)(2n+1) / 6
i=1
Q.2 (a) Answer the following 07
1.Draw FA for regular expression: (111+100)*0
2. Let M1 and M2 be the FA in fig below for the language L1 and L2, find L1 U L2 and L1
L2.
Q.3 (a) State the pumping lemma for regular language. Prove that {0 n1 n | n >= 0} is not a regular 07
language
(b) Convert the Given NFA into its equivalent DFA-
1
Q.4 (a) Give the context free grammar for the following languages. 07
1. L = { anbn |n>=0 }
2. Language for Palindroms.
3. Language for Non-Palindroms.
4. Language for Algebraic Expressions
5. L = { x belongs to {0,1}* | no(x) = n1(x) }
6. L = { x belongs to {0,1}* | no(x) ≠ n1(x) }
7. The set of odd-length strings in {a,b}* with middle symbol a.
(b) Define NFA and NFA-Λ. Convert the following NFA to DFA 07
*************