Theory of computation miscellaneous
- Which of the following is true?
-
View Hint View Answer Discuss in Forum
Finite subset of non-regular set is regular as we know that Pumping Lemma can be applied on all the finite sets that states that all finite sets are regular. Infinite union of finite set is not regular because regular sets can never be closed under infinite union.
Correct Option: B
Finite subset of non-regular set is regular as we know that Pumping Lemma can be applied on all the finite sets that states that all finite sets are regular. Infinite union of finite set is not regular because regular sets can never be closed under infinite union.
- Given below are two finite state automata ( → indicates the start state and F indicates a final state)
Which of the following represents the product automata Z × Y?
-
View Hint View Answer Discuss in Forum
Given : Transition table for Y and Z
The number of states of Z = 2
The number of states of Y = 2
Z × Y
No. of states of the product of Z and Y = 2 × 2 = 4
Now, the states as per the given options are P, Q, R and S. The finite state automata isCorrect Option: A
Given : Transition table for Y and Z
The number of states of Z = 2
The number of states of Y = 2
Z × Y
No. of states of the product of Z and Y = 2 × 2 = 4
Now, the states as per the given options are P, Q, R and S. The finite state automata is
- Let L = {W ∈ (0, 1) * | W has even number of 1s}, i.e., L is the set of all bit strings with even number of 1's. Which one of the regular expressions below represents L?
-
View Hint View Answer Discuss in Forum
It is given that L is the set of all bit strings with even number of 1's so the regular expression should exhibit the same. Now, the min string should be e and the string should be e, 0, 11, 101,... The string obtained from such expression is 0* (10* 10 *)*
Correct Option: B
It is given that L is the set of all bit strings with even number of 1's so the regular expression should exhibit the same. Now, the min string should be e and the string should be e, 0, 11, 101,... The string obtained from such expression is 0* (10* 10 *)*
- S → aSa |bSb| a | b; The language generated by the above grammar over the alphabet {a, b} is the set of
-
View Hint View Answer Discuss in Forum
Given grammar S → aSabSbab. The strings generated through this grammar is definitely palindromes,but not all it can only generate palindromes of odd length only so (A) & (D) are false, (B) is correct. Also it can generate palindromes which start and end with same symbol, but not all strings eg. aabababba .
Correct Option: B
Given grammar S → aSabSbab. The strings generated through this grammar is definitely palindromes,but not all it can only generate palindromes of odd length only so (A) & (D) are false, (B) is correct. Also it can generate palindromes which start and end with same symbol, but not all strings eg. aabababba .
-
The above DFA accepts the set of all strings over {0, 1} that
-
View Hint View Answer Discuss in Forum
Therefore, the above DFA ends with 00.Correct Option: C
Therefore, the above DFA ends with 00.