Theory of Computation (Chapter - Unit 3) Solved MCQs (Set-1)

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

Theory of Computation MCQs [set-1]

Chapter: Unit 3

1. Any Language generated by an unrestricted grammar is:


A. Recursive
B. Recursively Enumerable
C. Not Recursive
D. None of the above
Answer: A

2. The Family of recursive language is not closed under which of the following
operations:
o m
A. Union
. c
B. Intersection
te
C. Complementation
a
D. None of the above.
Answer: D q M
c
3. PCP is: M
A. Decidable
B. Undecidable
C. Sometimes Decidable
D. None of the
Answer: B

4. If PCP is decidable then MPCP is


A. Decidable
B. Undecidable
C. Can’t Say
D. None of the
Answer: C

5. Consider a language L for which there exists a Turing machine ™, T, that


accepts every word in L and either rejects or loops for every word that is not in L.
The language L is
A. NP hard
B. NP complete
C. Recursive
D. Recursively enumerable
Answer: D

6. Consider the following statements


I. Recursive languages are closed under complementation
II. Recursively enumerable languages are closed under union
III. Recursively enumerable languages are closed under complementation
Which of the above statement are TRUE?
A. I only
B. I and II
C. I and III
D. II and III
Answer: B

7. Recursively enumerable languages are not closed under


A. Union
B. homomorphism
C. complementation
D. concatenation
Answer: C

8. Which of the following problem is undecidable?


A. Membership problem for CFL
B. Membership problem for regular sets
C. Membership problem for CSL
D. Membership problem for type 0 languages
Answer: D

9. Recursive languages are


A. A proper superset of CFL
B. Always recognized by PDA
C. Are also called type 0 languages
D. Always recognized by FSA

Download more sets at McqMate.com


Answer: A

10. Consider the following problem x. Given a Turing machine M over the input
alphabet ?, any state q of M. And a word w ? ?*, does the computation of M on w
visit the state q? Which of the following statements about x is correct?
A. X is decidable
B. X is undecidable but partially decidable
C. X is undecidable and not even partially decidable
D. X is not a decision problem
Answer: A

11. If a language is denoted by a regular expression L = ( x )* (x y x ), then which of


the following is not a legal string within L ?
A. yx
B. xyx
C. x
D. xyxyx
Answer: D

12. Given A = {0,1} and L = A*. If R = (0n1n, n > 0), then language L ? R and R are
respectively
A. Regular, regular
B. Not regular, regular
C. Regular, not regular
D. Context free, not regular
Answer: D

13. If L1 and L2 are context free language and R a regular set, then which one of
the languages below is not necessarily a context free language?
A. L1 L2
B. L1 ? L2
C. L1 ? R
D. L1 ? L2
Answer: B

14. The logic of pumping lemma is a good example of


A. Pigeon-hole principle
B. Divide-and-conquer technique

Download more sets at McqMate.com


C. Recursion
D. Iteration
Answer: A

15. For two regular languages L1 = (a + b)* a and L2 = b (a + b ) *, the intersection


of L1 and L2 is given by
A. (a + b ) * ab
B. ab (a + b ) *
C. a ( a + b ) * b
D. b (a + b ) * a
Answer: D

16. Pumping lemma is generally used for proving that


A. Given grammar is regular
B. Given grammar is not regular
C. Whether two given regular expressions are equivalent or not
D. None of these
Answer: B

17. What is the highest type number which can be applied to the following
grammar? S —>Aa, A —> Ba, B —>abc
A. Type 0
B. Type 1
C. Type 2
D. Type 3
Answer: C

18. Following syntax-directed translation scheme is used with a shift reduction


(bottom up) parser that perform the action in braces immediately after a reduction
by the corresponding production
A —>aB {print “(1)” A —> c {print “1”),
B —>Ab {print *2”}.
When parser is aaacbbb, then string printed
A. 0202021
B. 1202020
C. 1020202
D. None of these

Download more sets at McqMate.com


Answer: A

19. FSM can recognize


A. Any grammar
B. Only CG
C. Both (a) and ( b )
D. Only regular grammar
Answer: D

20. Basic limitation of FSM is that it


A. Cannot remember arbitrary large amount of information
B. Sometimes fails to recognize grammars that are regular
C. Sometimes recognizes grammars are not regular
D. None of these
Answer: A

21. Which of the following are decidable?


1) Whether the intersection of two regular language is infinite.
2) Whether a given context free language is regular.
3) Whether two push down automata accept the same language.
4) Whether a given grammar is context free.
A. 1 and 2
B. 1 and 4
C. 2 and 3
D. 2 and 4
Answer: B

22. If L and L¯ are recursively enumerable, then L is


A. Regular
B. Context free
C. Context sensitive
D. Recursive
Answer: D

23. Which of the following problems is undecidable?


A. Membership problem for CFGs
B. Ambiguity problem for CFGs.
C. Finiteness problem for FSAs.

Download more sets at McqMate.com


D. Equivalence problem for FSAs.
Answer: B

24. Fred created a new automaton model which is a push down automaton but with
two stacks and the added ability of having commands which do not read input tape
but which can pop from one stack and push into the other.This new automaton can
recognize (choose strongest result)
A. Context Free Language
B. Context sensitive language
C. Regular language
D. Languages recognizable by Turing machine
Answer: D

25. Which of the following statements is/are FALSE?


(1) For every non-deterministic Turing machine, there exists an equivalent
deterministic Turing machine.
(2) Turing recognizable languages are closed under union and complementation.
(3) Turing decidable languages are closed under intersection and complementation
(4) Turing recognizable languages are closed under union and intersection.
A. 1 and 4 only
B. 1 and 3 only
C. 2 only
D. 3 only
Answer: C

Download more sets at McqMate.com

You might also like