Toc Questions Bank
Toc Questions Bank
PART-A
1. Define hypothesis.
2. Define inductive proof. Nov/Dec 2010
3. (Or) State the principle of induction Nov/Dec 2012
4. What is structural induction? May/June 2011
5. What is proof by contradiction? May/June
6. Define Set, Infinite and Finite Set.
7. Give some examples for additional forms of proof.
8. Prove 1+2+3+………………+n= n(n+1)/2 using induction method.
9. Write down the operations on set.
a. i ) A U B is Union Operation
ii) A ∩ B is Intersection operation
21. State the difference between NFA & DFA. May/June 2011& May/June 2014
Nov/Dec 2018
22. Define the term Epsilon(€) transition. May/June 2013
23. Define ξ –Closure (q) with an example. May/June 2012, Nov/Dec 2022
24. Draw a NFA to accept strings containing the substring 0101. May-June 2016
PART B
ii. Construct NFA for set of all strings {0,1} that ends with three consecutive 1‘s at its
end.
iii. Construct NFA for set of all strings {a,b} with abb as substring.
8. If a Regular language ‗L‘ is accepted by a Non – deterministic Finite automata then there
exist a Deterministic Finite Automata that accepts ‗L‘
Nov/Dec 2013&Nov/Dec 2014
9. A Language ‗L‘ is accepted by some ε – NFA if and only if L is accepted by NFA without ε
transition May/June 2012 & Nov/Dec
2013
10. Convert to a DFA, the following NFA May/June 2013
a b
p(start) {p} {p,q}
q {r} {r}
r {Φ} {Φ}
11. Convert the following NFA-with ε, to a NFA- without ε
ε
0 1 2
q0
{q0} {φ} {φ} {q1}
(start)
q1 {φ} {q1} {φ} {q2}
* q2 {φ} {φ} {q2} {φ}
a b c ε
15. Construct a DFA accepting binary strings such that the third symbol from the right end is 1 C
May/June 2012
16. Construct NFA without ε transitions for the NFA given below
17. Construct an NFA accepting binary strings with two consecutive 0‘s. May/June 2012
18. Explain different forms of proof with examples. May/June 2012
19. i. Prove that if n is a positive integer such that n mod 4 is 2 or 3 then n is not a perfect square.
May/June 2012
20. i. Construct DFA to accept the language L= { w / w I of even length and begins with 11}
ii. Write a note on NFA and compare with DFA. May/June 2013
21. Construct DFA equivalent to the NFA given below: Nov/Dec 2013
24. Construct a DFA that accepts all strings on {0,1} except those containing the substring 101.
May/June 2014
25. i. Construct a NFA accepting the set of strings over {a,b} ending in aba. Use it to construct a DFA
accepting the same set of strings. May/June 2014
ii. Construct NFA with ε moves which accepts a language consisting the stings of any
number of a‘s, followed by any number of b‘s, followed by any number of c‘s.
2
26. Prove that L={0 i / i is an integer; i>0} is not regular. Nov/Dec 2014, 2015
27. i. Prove that every tree has ‗e‘ edges and ‗e+1‘ nodes. Nov/Dec 2014
ii. Prove that for every integer n 0 the number 42n+1+3n+2 is a multiple of 13.
28. Construct a DFA equivalent to the the NFA M=({a,b,c,d},{0,1}, δ,a,{b,d}) where δ is
defined as C
Nov/Dec 2014
δ 0 1
a {b,d} {b}
b c {b,c}
c d a
d - a
29. Design a DFA accepts the following strings over the alphabets {0, 1} that contain a pattern
11. Prove this using mathematical induction. April/May 2015
30. Design a NFA accept the following strings over the alphabets {0,1} that begins with 01 and ends
with 11. Check for the validity of 01111 and 0110 strings. April/May 2015
31. Prove that ―A language L is accepted by some DFA if and only if L is accepted by some
NFA‖.
32. Consider the following ε-NFA for an identifier. Consider the ε-closure of each state and find it‘s
equivalent DFA. (10) Nov/Dec 2015
33. Construct a NFA that accepts all strings hat end in 01. Give its transition table and extend
transition function for the input string 00101. Also construct a DFA for the above NFA using
subset construction method. May-June2016
37. Convert the epsilon NFA and list the difference between NFA and DFA.
Nov-Dec2017
38. Convert the following E-NFA to NFA and then convert the resultant NFA to DFA.
Nov-Dec 2018
39. Prove that a language L is accepted by some NDFA if and only if L is accepted by some DFA.
Nov-Dec 2018
0 1
P(start) {p,q} {p}
Q {r} {r}
R {s} -
S {s} {s}
42. Give NFA accepting the set of strings in (0+1)* such that two 0‘s are separated by a string whose
length is 4i, for some i>=0. Nov-Dec 2019
43. Construct a minimized DFA from R.E (x+y)x(x+y)*. Trace for a string w=xxyx.
Nov/Dec 2011
UNIT II REGULAR EXPRESSIONS AND LANGUAGES
PART A
2. Give the regular expression for set of all strings ending in 00. Nov/Dec 2010
3. State pumping lemma for regular language. Nov/Dec 2022
Nov/Dec 2010, 2013 , 2014 & 2017 , May-June 2016,
Nov/Dec2018,2019
4. Give the regular expression for the following Nov/Dec 2012
L1= set of all strings of 0 and 1 ending in 00
L2= set of all string 0 and 1 beginning with 0 and ending with 1
5. Name any four CFG. May/June 2013& May/June 2014 Nov-Dec 2016
10. Write RE for the set of strings over {0,1} that have atleast one. Nov/Dec
2015
11. Show whether a language L=(0n12n/n>0} is regular or not using pumping Lemma.
May-June 2017
PART-B
1. State and explain the conversion of DFA into R.E using Arden‘s theorem. Illustrate with an example.
Nov/Dec 2011
7. i. Using pumping lemma for the regular sets, prove that the language L={ambn/m>n} is not regular.
ii. Prove any two closure properties of regular languages. Nov/Dec 2012
23. Minimize the FA shown in fig below and show both the given and the reduced one are equivalent.
May/June 2014
24. Write and explain the algorithm for minimization of a DFA. Using the above algorithm minimize the
following DFA. May-June2016
25. Construct NFA with epsilon for the R.E=(a/b)*ab and convert into DFA and further find the minimized
DFA. C May-June 2017
26. Show that the regular language are closed under : Nov-Dec2017
o Union
o Intersection
o Kleen closure
o Complement
o Difference
27. Minimize the following automaton Nov-Dec 2018
29. Prove that any language accepted by a DFA can be represented by regular expression.
Nov-Dec 2019
30. Construct a finite automata for the RE 10+(0+11)0*1 Nov-Dec 2019
31. Prove that the following languages are not regular: Nov-Dec 2019
i. {w€{a,b}*/w=w } r
ii. Set of string of 0‘s and 1‘s beginning with a 1, whose value treated as binary number is a
prime.
UNIT III
3. What is derivation?
6. For the grammar defined by the productions recognize the string 1001 and also construct the
parse tree.
7. Consider the alphabet Σ = { a,b,(,),+,*,-, . ,ξ }. Construct a CFG that generate all the strings in Σ*
that are regular expression on the alphabet, Σ. C
Nov/Dec 2007
8. Find LMD & RMD, parse tree for the following grammar. May/June 2007
12. Write the CFG for the following CFL L(G) = {𝑎𝑚𝑏𝑛𝑐𝑝/ m+n=p, m&n>1}
Nov/Dec 2006
13. Let G = ( {S,C}, {a,b}, P,S} where P consists of S aCa, C aCa, Find L(G))?
14. What is the language generated by the grammar G=(V,T,P,S) where P={S-
>aSb, S->ab}?
17. Find the grammar for the language L={a2n bc ,where n>1 }
20. Construct a grammar for the language L which has all the strings which are all palindrome over
_={a, b}. May/June 2014 , Nov/Dec 2015
24. Give the general forms of CNF. (Or) State CNF. R Nov/Dec 2014, Nov-Dec 2016
25. Construct the CFG for the language. L(G) = {01 1𝑛 / n > 1} C Nov/Dec 2013
26. What is meant by GNF? May/June 2013.
27. Is the grammar ambiguous SSS/(S)/S(S)S/ ξ? Nov/Dec 2011
28. Convert the following grammar into an equivalent one with no unit productions and no useless
symbols S ABA A aAA/aBC/bB BA/bB/Cb
CCC/cC. Nov/Dec 2011
34. Generate CFG for a signed integer constant in C language. May- June 2017
35. Derive the string “aabaab” for the following CFG Nov/Dec 2017
SaSX/b
XXb/a
F – Final state.
S → aab
What are the different ways of language acceptance by a PDA and define them?
. Nov/Dec 2012 ,April/May2015, Nov/Dec 2015
43. What is the additional feature PDA has when compared with NFA?Is PDA superior over NFA in
the sense of language acceptance? justify? (Or)
Compare NFA & PDA. Nov/Dec 2013
46. Construct a RMD of (a+b)*c using the grammar and also state that whether a given grammar is
ambiguous or not. May- June 2017
EE+E
EE*EE
(E)
Ea | b | c
47. Differentiate PDA acceptance by empty stack with acceptance by final state.
May- June 2017
13. Construct a PDA for the language L={x€{a,b}*/ na(x)>nb(x)} April/May 2015
29. Explain about parse tree. For the following grammar. May/June 2013
For the string aaabbabbba, Find i. LMD ii. RMD iii. Parse tree Nov/Dec 2015
32. Let G=(V,T,P,S) be a CFG then prove that if the recursive inference procedure tells us that terminal
string W is in the language of variable A, then there is a parse tree with root A and yield w. A
Nov/Dec 2015
33. Given the Grammar G=(V,∑, R,E), Where
V= {E,D,1,2,3,4,5,6,7,8,9,0,+,-,*,/,(,)}
∑={1, 2,3,4,5,6,7,8,9,0,+,-,*,/,(,)} and
R contains the following rules:
ED|(E)|E+E|E-E|E*E|E/E
D0|1|2…..9. Find a parse tree for the string 1+2*3
34. What is ambiguous grammar? Explain with an example.
Nov/Dec2015, May-June2016
35. Show the derivation steps and construct derivation tree for the string ababbb' by using left most
derivation with the grammar. May-June2016
S —> AB / ξ, A—> aB, B—> Sb
36. Construct a CFG for the regular expression (011+1) (01). May-June2016
37. Construct CFG for the language L={an/n is odd} Nov-Dec2016
38. Define derivation tree. Explain its uses with an example. Nov-Dec2016
39. Construct a CFG to generate even and odd set of palindrome over alphabet {a,b}.
Nov-Dec2017
40. Generate CFG for the language L={0i1j0k/j>i+k} Nov-Dec2017
41. Show that the following grammar is ambiguous: SSbS/a. An Nov-Dec 2018
8. Define Turing Machine. R Nov/Dec 2010,2015& 2017 , May/June 2014 & 2016
9. What are the required fields of an instantaneous description or configuration of a TM? R
10. What is multiple tracks Turing machine? R
11. What is multidimensional Turing machine? R
14. List out the different techniques for TM construction. R Nov/Dec 2013
PART B
n n n
1. Is the language L = {a b c | n>=1} is context free? Justify. AN Nov/Dec 2010 (Or)
Show that the Language L={ a i b i c i/ i 1} is not context free. A May/June 2014
11. Construct a equivalent grammar G in CNF for the grammar G1 where G1=({S,A,B}, {a,b},
{ SASB/£, AaAS/a, BSbS/A/bb},S). C Nov/Dec 2015
12. Given the CFG G, find CFG G‘ in CNF generating the language L(G)-{^}
SAACD
AaAb/^
CaC/a
DaDa/bDb/^ A April/May 2015
13. Construct a reduced grammar equivalent to the grammar G = (N, T, P, S) where, N =
{S. A, C, D, E} T= {a, b} C
P = { S —> aAa, A —> Sb, A —> bCC, A —> DaA, C —> abb. C —> DD, E aC,
D —> aDA}. C May-June2016
14. What is the purpose of normalization? Construct the CNF and GNF for the following grammar
and explain the steps. A May-June2016
16. Given the CFG G, find CFG G‘ in CNF generaring the language L(G)- { ξ}
51. Prove that the language L={anbncn/n>=1} is not context free using pumping lemma
52. Give the five tuple representation of a TM and explain the representation. Define the
language accepted by a TM. U Nov-Dec2018\
53. Design TM that accepts the language L={SS/ S is in {a,b}* C Nov-Dec2018
54. Design TM for L={anbncn/n>=1} U Nov-Dec2018
55. Suppose L=L(G) for some CFG G=(V<T<P<S) then prove that L-{ ξ } is L(G‘) for CFG G‘ with no
useless symbols or ξ- production. E Nov-Dec2019
56. State and prove GNF. E Nov-Dec201
57. Design TM to compute proper subtraction. C Nov-Dec2019
UNIT V UNDECIDABILITY
PART A
13. What are the properties of recursive and recursively enumerable language?
14. Mention the difference between decidable and undecidable problems.
Nov/Dec 2010
14. Show that any PSPACE-hard language is also NP-hard. Nov/Dec 2010
15. Mention the difference between P and NP problems. May/June 2012
20. Identify whether 'Tower of Hanoi' problem is tractable or intractable. Justify your answer.
May-June2016
1. Prove that ‗If ‗L‘ is a recursive language, then L‘ is also a Recursive Language‘. E
2. Prove that ‗If a language L and L‘ are recursively enumerable (RE) , then L is Recursive‘. E
3. Prove that (i) Lu is recursively enumerable but not recursive. E
(ii) Non empty language Lne is recursively enumerable.
4. Find the languages obtained from the following operations: A
(i) Union of two recursive languages. (6) Nov/Dec 2014
(ii) Union of two recursively enumerable languages (6)
(iii) L if L and complement of L are recursively enumerable (4)
5. a) Show that the following language is not decidable. E L={<M>| M
is a TM that accepts the string aaab}. (8)
b) Discuss the properties of Recursive and Recursive enumerable
languages. U (8)
6. Prove that the universal language Lu is recursively enumerable. E
May/June 2014 , Nov/Dec 2014, Nov/ Dec 2015
7. Define the universal language and show that it is recursively enumerable but
not recursive. U
8. Whether the problem of determining given recursively enumerable
language is empty or not? Is decidable? Justify your answer. AN
9. Define Universal language Lu. Show that Lu is recursively enumerable but not recursive. U
10. Explain the Halting problem. Is it decidable or undecidable problem? U
Nov/DEC 2011 , Nov/Dec 2012
11. Explain the difference between tractable and intractable problems with examples. U
Nov/Dec 2010
12. Write short notes on: i. Recursive and recursively enumerable language
ii. NP hard and NP complete Problems U Nov/Dec 2011
13. Discuss the properties of recursive languages. U May/June 2012
14. Explain any two undecidable problems with respect to TM. U
May/June 2012 , May/June 2013
15. Discuss the difference between NP-complete and NP-hard problems. May/June 2012
U
16. Write note on NP problems. U Nov/Dec 2012, Nov/Dec 2013
17. Explain about ―A language that is not Recursively Enumerable‖.U
May/June 2013
18. Prove that for two recursive language L1 and L2 their union and intersection is recursive. A
Nov/Dec 2013.
19. Explain post correspondence problems and decidable and undecidable problems with examples. U
April/May 2015
20. Explain the class P and NP problems with suitable example. U April/May 2015
21. Prove that ―MPCP reduce to PCP‖. A Nov/Dec 2015
22. Discuss about the tractable and intractable problems. U Nov/Dec 2015
23. State and explain RICE theorem. U Nov/Dec 2015
24. Describe about Recursive and Recursively Enumerable languages with examples.
U Nov/Dec 2015
25. What is Universal Turing Machine? Bring out its significance. Also construct a TM to add two numbers
and encode it. U May-June 2016
26. What is post correspondence problem (PCP) Explain with the help of an example. U
May-June 2016, Nov-Dec2018
27. Elaborate on primitive recursive functions with an example. U Nov-Dec2016
28. Compare recursive language with recursively enumerable languages.
AN Nov-Dec2016
29. What are tractable problems? Compare with intractable problems.
30. Outline the concept of polynomial time reductions. U Nov-Dec2016
30. Explain recursive and recursively enumerable languages with suitable example.
U May-June2107
31. Explain tractable and intractable problem with suitable example.
U May-June2107
32. Explain universal TM. U Nov-Dec2017
33. Explain how to measure and classify complexity. U Nov-Dec2017
34. If L and its complement are recursively enumerable language, prove that L is recursive. E Nov-
Dec 2018