MCQ Computer Science
Automata Theory Multiple Choice Question & Answers (MCQs) set-12
1. The password to the admins account=”administrator”. The total number of states required to make a password-pass system using DFA would be __________
a) 14 states
b) 13 states
c) 12 states
d) A password pass system cannot be created using DFA
View Answer
Answer: a
Explanation: For a string of n characters with no repetitive substrings, the number of states required to pass the string is n+1.
Explanation: For a string of n characters with no repetitive substrings, the number of states required to pass the string is n+1.
a) u-1
b) v-1
c) u-1v-1
d) ε
View Answer
Answer: d
Explanation: Identity relation: εw = wε = w, thus the one satisfying the given relation will be the identity element.
Explanation: Identity relation: εw = wε = w, thus the one satisfying the given relation will be the identity element.
a) 3
b) 2
c) 1
d) can’t be represented.
View Answer
Answer:a
Explanation: This is minimal finite automata.
Explanation: This is minimal finite automata.
Note: S is a subset of Q and a is a symbol.
a) δ’ (S, a) =Upϵs δ (p, a)
b) δ’ (S, a) =Up≠s δ (p, a)
c) δ’ (S, a) =Upϵs δ(p)
d) δ’ (S) =Up≠s δ(p)
View Answer
Answer: a
Explanation: According to subset construction, equation 1 holds true.
Explanation: According to subset construction, equation 1 holds true.
a) Accepted by NFA
b) Rejected by NFA
c) One of them will be accepted
d) Cannot be said
View Answer
Answer: a
Explanation: If L is a regular Language, Lc and Lr both are regular even.
Explanation: If L is a regular Language, Lc and Lr both are regular even.
a) Quadruple
b) Quintuple
c) Triple
d) None of the mentioned
View Answer
Answer: b
Explanation: An e-NFA consist of 5 tuples: A=(Q, S, d, q0, F)
Note: e is never a member of S.
Explanation: An e-NFA consist of 5 tuples: A=(Q, S, d, q0, F)
Note: e is never a member of S.
a) Phi
b) Null
c) (0+1)*
d) (0+1)
View Answer
Answer:c
Explanation: There is only one state which is start and final state of DFA so interchanging starting start and final state doesn’t change DFA.
Explanation: There is only one state which is start and final state of DFA so interchanging starting start and final state doesn’t change DFA.
a) {0, 1, 01, ε}
b) {0, 1, ε}
c) {0, 1, 01 ,11, 00, 10, ε}
d) {0, 1}
View Answer
Answer: a
Explanation: The regular expression is fragmented and the set of the strings eligible is formed. ‘+’ represents union while ‘.’ Represents concatenation.
Explanation: The regular expression is fragmented and the set of the strings eligible is formed. ‘+’ represents union while ‘.’ Represents concatenation.
a) (a +b) *c
b) (a)+((b)*.c)
c) (a + (b*)).c
d) a+ ((b*).c)
View Answer
Answer: d
Explanation: Following the rules of precedence, Kleene or star operation would be done first, then concatenation and finally union or plus operation.
Explanation: Following the rules of precedence, Kleene or star operation would be done first, then concatenation and finally union or plus operation.
a) Yes
b) No
View Answer
Answer: a
Explanation: Using different sequence of removal of state, we can have different possible solution of regular expressions. For n-state deterministic finite automata excluding starting and final states, n! Removal sequences are there. It is very tough to try all the possible removal sequences for smaller expressions.
Explanation: Using different sequence of removal of state, we can have different possible solution of regular expressions. For n-state deterministic finite automata excluding starting and final states, n! Removal sequences are there. It is very tough to try all the possible removal sequences for smaller expressions.
a) Union
b) Intersection
c) Kleen star
d) All of the mentioned
View Answer
Answer : d
Explanation : According to definition of regular expression.
Explanation : According to definition of regular expression.
a) search engines
b) word processors
c) sed
d) none of the mentioned
View Answer
Answer: d
Explanation: Regexp processors are found in several search engines, seach and replace mechanisms, and text processing utilities.
Explanation: Regexp processors are found in several search engines, seach and replace mechanisms, and text processing utilities.
a) Parsing
b) Interpretation analysis
c) Lexicography
d) Lexical Analysis
View Answer
Answer: d
Explanation: Lexical analysis or scanning is the process of parsing the source code into proper syntactic classes. It gets things ready for the parser with lexemes to built the parse tree.
Explanation: Lexical analysis or scanning is the process of parsing the source code into proper syntactic classes. It gets things ready for the parser with lexemes to built the parse tree.
a) Emptiness
b) Universality
c) Membership
d) None of the mentioned
View Answer
Answer: d
Explanation: All the following mentioned are decidability properties of a regular language. The closure properties of a regular language include union, concatenation, intersection, Kleene, complement , reverse and many more operations.
Explanation: All the following mentioned are decidability properties of a regular language. The closure properties of a regular language include union, concatenation, intersection, Kleene, complement , reverse and many more operations.
a) L’
b) Lc
c) Lr
d) more than one option is correct
View Answer
Answer: c
Explanation: Lr is defined as the reversal of a language. Lr is a set of strings whose reversal is in L.
Example: L={0, 01, 100}
Lr={0, 10, 001}
Explanation: Lr is defined as the reversal of a language. Lr is a set of strings whose reversal is in L.
Example: L={0, 01, 100}
Lr={0, 10, 001}