Attempt any Eight questions.
[8*5=40]
4.
Define string, substring, empty string, and empty language over alphabet {a,b}. [5]
5.
Design a DFA that accepts single line and multi-line comments of the C-Language. [5]
6.
Write regular expression over {a,b} that represents a. Strings having exactly two a's and at least two b's. b. Strings having an even number of a's and each a followed by at least one b. [5]
7.
Using pumping lemma, prove that the language is not regular. L={aibjck∣j=i+k} [5] 8.
Design a PDA over {x,y} which accepts strings defined by the language Show acceptance of xxyy. L={xnynxy∣n≥0} [5] 9.
Design a Turing machine that computes a function f(n)=0. [5]
10.
How abstract, decision and optimization problems are different from each other? [5]
11.
How is PDA to CFG conversion done? Consider a PDA that accepts by empty stack, Now construct an equivalent CFG. P=((p,q);{0,1},{Z},δ,p,Z); δ(p,0,Z)=(p,0z),δ(p,0,0)=(p,00),δ(p,1,0)=(p,ε),δ(p,ε,z)=(q,ε) [5] 12.
What is the meaning of the term 'Context Free' in context free grammar? Justify with a suitable example. What is the need of a parse tree? [5]