0% found this document useful (0 votes)
10 views5 pages

Toc

The document presents a series of questions related to finite automata, languages, and grammars, covering topics such as regular expressions, deterministic finite automata (DFA), context-free grammars, and properties of languages. It includes multiple-choice questions that assess understanding of concepts like the relationship between DFA and NFA, the characteristics of dead states, and the nature of regular languages. Additionally, it outlines definitions and key concepts in automata theory and formal languages.

Uploaded by

shareassassin
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views5 pages

Toc

The document presents a series of questions related to finite automata, languages, and grammars, covering topics such as regular expressions, deterministic finite automata (DFA), context-free grammars, and properties of languages. It includes multiple-choice questions that assess understanding of concepts like the relationship between DFA and NFA, the characteristics of dead states, and the nature of regular languages. Additionally, it outlines definitions and key concepts in automata theory and formal languages.

Uploaded by

shareassassin
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

1. For the following Finite Automata which is not the correct output starting?

The language b accepted by this


automata is given by the regular expression:

i. b*ab*ab*ab*
ii. (a + b)*
iii. b*a (a + b)*
iv. b* ab* ab*

2. Consider the following deterministic finite automaton (DFA) defined over the alphabet, Σ = {a, b}. Identify which
of the following language(s) is/are accepted by the given DFA.

i. The set of all string containing an even number of b’s.


ii. The set of all string containing the pattern bab.
iii. The set of all string ending with the pattern bab.
iv. The set of all string not containing the pattern aba.

3. _______ is the most general phase structured grammar.

i. Regular
ii. Context free
iii. Context sensitive
iv. All of the above

4. Identify the language generated by the following grammar, where S is the start variable.
S-XY
X-aX | a
Y-aYb | ∈

i. {ambn | m ≥ n, n > 0}
ii. {ambn | m ≥ n, n ≥ 0}
iii. {ambn | m > n, n ≥ 0}
iv. {ambn | m > n, n > 0}

5. Which of the following is a not a part of 5-tuple finite automata?

i. Input Alphabet
ii. Transition function
iii. Output Alphabet
iv. Initial State

6. Given the language L = {ab, aa, baa}, which of the following strings are in L?

i. abaabaaabaa
ii. aaaabaaaa
iii. baaaaabaa
iv. All of these

7. The finite automata are called NFA when there exists ________ for a specific input from current state to next
state

i. Multiple paths
ii. Single path
iii. Only two paths
iv. None

8. What is the relation between DFA and NFA on the basis of computational power?

i. DFA > NFA


ii. Equal
iii. NFA > DFA
iv. Can’t be said

9. Which is true for Dead State?

i. There is no necessity of the state


ii. It cannot be reached anytime
iii. If control enters no way to come out from the state
iv. If control enters FA dead

10. Which of the following languages is generated by the given grammar?


S aS | bS | ∈
n m
i. {a b | n, m ≥ 0}
ii. {w ∈ {a,b} * | w has equal number of a's and b's}
iii. {an | n ≥ 0} ∪ {bn | n ≥ 0} ∪ {anbn | n ≥ 0}
iv. (a + b)*

11. The minimum possible number of states of a deterministic finite automation that accepts the regular language
L = {W₁aW2 | W1, W2 ∈ (a,b)*, |W₁| = 2, |W2| ≥ 3} is________.
i. 8
ii. 5
iii. 4
iv. 2
12. Language L₁ is defined by the grammar: S₁ aS₁b | ∈
Language L₂ is defined by the grammar: S2 abS2 | ∈
Consider the following statements:
P: L₁ is regular
Q: L2 is regular

Which one of the following is TRUE?

i. Both P and Q are true


ii. P is true and Q is false
iii. P is false and Q is true
iv. Both P and Q are false

13. If L is a regular language over ∑ = (a, b), which one of the following languages is NOT regular?

i. L. LR = {xy | x ∈ L, yR ∈ L}
ii. {wwR | w ∈ L}
iii. Prefix (L) = {x ∈ Σ* | Ǝx ∈ Σ* such that xy ∈ L}
iv. Suffix (L) = {y ∈ Σ* | Ǝx ∈ Σ* such that xy ∈ L}

14. Let G1, G2 be Context-Free Grammars (CFGs) and R be a regular expression. For a grammar G, let L(G) denote
the language generated by G.
Which ONE among the following questions is decidable?

i. Is L(G1) = L(G2)?
ii. Is L(G1) ꓵ L(G2)?
iii. Is L(G1) = L(R)?
iv. Is L(G1) = ∅?

15. Consider the language L given the regular expression (a+b)*b(a+b) over the alphabet {a,b}. The smallest
number of states needed in a deterministic finite-state automation (DFA) accepting L is ________.
i. 6
ii. 4
iii. 2
iv. 8

16. Which ONE of the following languages is accepted by a deterministic pushdown automaton?

i. Any regular language.


ii. Any context-free language.
iii. Any language accepted by a non-deterministic pushdown automation.
iv. Any decidable language.

17. Consider the context-free grammar G below


S → aSb ∣ X
X → aX ∣ Xb ∣ a ∣ b
where S and X are non-terminals, and a and b are terminal symbols. The starting non-terminal is S.
Which one of the following statements is CORRECT?
i. The language generated by G is (a+b)*
ii. The language generated by G is a*(a+b)b*
iii. The language generated by G is a*b*(a+b)
iv. The language generated by G is not a regular language

18. Which of the following statements is/are not CORRECT?

i. The intersection of two regular languages is regular.


ii. The intersection of two recursively enumerable languages is recursively enumerable.
iii. The intersection of two recursive languages is recursive.
iv. All of these.

19. Empty string is denoted by_____.

i. ∅
ii. 𝛿
iii. ∑
iv. 𝜺

20. DFA transition function can be defined as_______.

i. 𝛅: 𝐐 × ∑→ 𝐐
ii. W: Q × ∑→ Q
iii. δ: Q × ∑→ W
iv. δ: Q × ∑→ F

21. If L is a regular language, then its Kleene closure L1* will_______.

i. Be a context-free language.
ii. Be a regular language.
iii. Be a non-regular language.
iv. Not be a language.

22. A grammar is said to be ambiguous if______.

i. There exists more than one leftmost derivation


ii. More than one rightmost derivation
iii. More than one parse tree for the given input string
iv. None
v. All of these

23. For every regular language accepted by ________ minimum DFA.

i. Multiple distinct minimum DFAs


ii. Only one unique minimum DFA
iii. No DFA at all
iv. An infinite number of DFAs
24. In DFA, every string (valid/invalid) has exactly ____ path.

i. 2
ii. 1
iii. 4
iv. 5

25. Consider the following two statements about regular languages:


S1: Every infinite regular language contains an undecidable language as a subset.
S2: Every finite language is regular.
Which one of the following choices is correct?

i. Only S1 is true
ii. Only S2 is true
iii. Both S1 and S2 are true
iv. Neither S1 nor S2 is true

5-15 Marks

1. Definition of DFA, NFA, GRAMMAR, Mealy, Moore Machine, (Clean Closer, Positive Closer and relation
between them)
2. DFA minimisation
3. Construct DFA & Regular Expression
4. CA questions
5. Chomsky Hierarchy
6. Production rules to Grammar
7. Ambiguous Unambiguous checking
8. Arden's theorem
9. What is pumping lemma for regular Expression
10. Pushdown Automata

You might also like