Explore topic-wise InterviewSolutions in .

This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.

51.

The O/P of Moore machine can be represented in the following format:(a) Op(t)=δ(Op(t))(b) Op(t)=δ(Op(t)i(t))(c) Op(t): ∑(d) None of the mentionedI got this question in an online quiz.The question is from Moore Machine topic in section Finite Automata of Automata Theory

Answer»

The correct option is (a) Op(t)=δ(Op(t))

The best I can explain: Op(t)=δ(Op(t)) is the defined DEFINITION of how the output is received on giving a SPECIFIC input to MOORE MACHINE.

52.

If L1 and L2 are regular sets then intersection of these two will be(a) Regular(b) Non Regular(c) Recursive(d) Non RecursiveThe question was asked during an internship interview.This question is from Union, Intersection & Complement topic in section Finite Automata of Automata Theory

Answer»

The CORRECT CHOICE is (a) Regular

The EXPLANATION is: Regular EXPRESSION are also colsed under intersection.

53.

Which of the following is type 3 language ?(a) Strings of 0’s whose length is perfect square(b) Palindromes string(c) Strings of 0’s having length prime number(d) String of odd number of 0’sThe question was posed to me by my school teacher while I was bunking the class.The doubt is from Union, Intersection & Complement in section Finite Automata of Automata Theory

Answer»

Correct answer is (d) String of ODD number of 0’s

The explanation: Only d is REGULAR language.

54.

Which of the following does the given NFA represent?(a) {11, 101} * {01}(b) {110, 01} * {11}(c) {11, 110} * {0}(d) {00, 110} * {1}This question was posed to me by my college director while I was bunking the class.My question comes from The Language of NFA topic in section Finite Automata of Automata Theory

Answer»

Correct answer is (C) {11, 110} * {0}

The best I can EXPLAIN: The given diagram can be ANALYSED and THUS the option can be seeked.

55.

The number of tuples in an extended Non Deterministic Finite Automaton:(a) 5(b) 6(c) 7(d) 4I got this question by my school teacher while I was bunking the class.This question is from Extended Transition Function in section Finite Automata of Automata Theory

Answer» CORRECT CHOICE is (a) 5

Explanation: For NFA or extended TRANSITION function on NFA, the tuple ELEMENTS REMAINS same i.e. 5.
56.

The basic limitation of finite automata is that(a) It can’t remember arbitrary large amount of information.(b) It sometimes recognize grammar that are not regular.(c) It sometimes fails to recognize regular grammar.(d) All of the mentionedThe question was posed to me by my school principal while I was bunking the class.Query is from Finite Automata topic in section Finite Automata of Automata Theory

Answer»

The correct CHOICE is (a) It can’t remember ARBITRARY large AMOUNT of information.

The explanation: Because there is no memory ASSOCIATED with automata.

57.

How many DFA’s exits with two states over input alphabet {0,1} ?(a) 16(b) 26(c) 32(d) 64This question was addressed to me during an online exam.This key question is from Finite Automata topic in chapter Finite Automata of Automata Theory

Answer»

The CORRECT OPTION is (d) 64

Best explanation: Number of DFA’s = 2^N * n^(2*n).

58.

Let the given DFA consist of x states. Find x-y such that y is the number of states on minimization of DFA?(a) 3(b) 2(c) 1(d) 4I got this question in semester exam.The doubt is from DFA Processing Strings in portion Finite Automata of Automata Theory

Answer»

The correct ANSWER is (B) 2

The EXPLANATION: Use the equivalence theorem or Myphill Nerode theorem to minimize the DFA.

59.

Which of the following x is accepted by the given DFA (x is a binary string ∑= {0,1})?(a) divisible by 3(b) divisible by 2(c) divisible by 2 and 3(d) divisible by 3 and 2This question was addressed to me during a job interview.I'd like to ask this question from The Language of DFA topic in portion Finite Automata of Automata Theory

Answer»

The CORRECT answer is (d) divisible by 3 and 2

Best EXPLANATION: The given DFA ACCEPTS all the BINARY STRINGS such that they are divisible by 3 and 2.Thus, it can be said that it also accepts all the strings which is divisible by 6.

60.

Let ∑= {a, b, …. z} and A = {Hello, World}, B= {Input, Output}, then (A*∩B) U (B*∩A) can be represented as:(a) {Hello, World, Input, Output, ε}(b) {Hello, World, ε}(c) {Input, Output, ε}(d) {}I got this question in homework.My query is from DFA Processing Strings topic in portion Finite Automata of Automata Theory

Answer»

Right ANSWER is (d) {}

Easiest explanation: Union OPERATION creates the UNIVERSAL set by combining all the elements of FIRST and second set while intersection operation creates a set of common elements of the first and the second STATE.

61.

Let N (Q, ∑, δ, q0, A) be the NFA recognizing a language L. Then for a DFA (Q’, ∑, δ’, q0’, A’), which among the following is true?(a) Q’ = P(Q)(b) Δ’ = δ’ (R, a) = {q ϵ Q | q ϵ δ (r, a), for some r ϵ R}(c) Q’={q0}(d) All of the mentionedThe question was asked in an interview for job.I would like to ask this question from Applications of DFA in chapter Finite Automata of Automata Theory

Answer»

Right OPTION is (d) All of the MENTIONED

Easiest EXPLANATION: All the optioned mentioned are the instruction formats of how to convert a NFA to a DFA.

62.

Which of the following options is correct for the given statement?(a) Statement: If K is the number of states in NFA, the DFA simulating the same language would have states less than 2^k.(b) True(c) FalseThis question was posed to me in exam.This key question is from Applications of DFA topic in portion Finite Automata of Automata Theory

Answer»

The correct answer is (a) Statement: If K is the number of states in NFA, the DFA simulating the same language WOULD have states less than 2^k.

For EXPLANATION: If K is the number of states in NFA, the DFA simulating the same language would have states equal to or less than 2^k.

63.

Number of times the state q3 or q2 is being a part of extended 6 transition state is(a) 6(b) 5(c) 4(d) 7This question was addressed to me during an online interview.I need to ask this question from Extended Transition Function topic in division Finite Automata of Automata Theory

Answer»

Correct choice is (a) 6

Easy EXPLANATION: According to the QUESTION, PRESENCE of Q2 or q1 would count so it does and the ANSWER according to the diagram is 6.

64.

δ*(q,ya) is equivalent to .(a) δ((q,y),a)(b) δ(δ*(q,y),a)(c) δ(q,ya)(d) independent from δ notationThe question was asked in quiz.I'd like to ask this question from Finite Automata in section Finite Automata of Automata Theory

Answer» CORRECT option is (B) δ(δ*(Q,y),a)

To explain I WOULD say: First it parse y string after that it parse a.
65.

There are ________ tuples in finite state machine.(a) 4(b) 5(c) 6(d) unlimitedThe question was posed to me in unit test.The origin of the question is Finite Automata in division Finite Automata of Automata Theory

Answer»

Correct answer is (b) 5

The best I can EXPLAIN: STATES, input symbols,initial STATE,accepting state and transition function.

66.

Which of the following will not be accepted by the following DFA?(a) ababaabaa(b) abbbaa(c) abbbaabb(d) abbaabbaaThis question was posed to me in an online quiz.My question comes from Deterministic Finite Automata-Introduction and Definition topic in division Finite Automata of Automata Theory

Answer»

The correct option is (a) ababaabaa

The best EXPLANATION: All the STRINGS are getting accepted EXCEPT ‘ababaabaa’ as it is directed to dumping state. Dumping state also refers to the reject state of the AUTOMATA.

67.

John is asked to make an automaton which accepts a given string for all the occurrence of ‘1001’ in it. How many number of transitions would John use such that, the string processing application works?(a) 9(b) 11(c) 12(d) 15I got this question in a job interview.This intriguing question comes from Applications of NFA in division Finite Automata of Automata Theory

Answer» CORRECT ANSWER is (a) 9

Explanation: NONE.
68.

In NFA, this very state is like dead-end non final state:(a) ACCEPT(b) REJECT(c) DISTINCT(d) STARTThis question was addressed to me during an interview for a job.The doubt is from The Language of NFA in chapter Finite Automata of Automata Theory

Answer» CORRECT CHOICE is (b) REJECT

Explanation: REJECT state will be LIKE a halting state which rejects a particular invalid INPUT.
69.

When are 2 finite states equivalent?(a) Same number of transitions(b) Same number of states(c) Same number of states as well as transitions(d) Both are final statesI had been asked this question during an interview for a job.My query is from Deterministic Finite Automata-Introduction and Definition topic in portion Finite Automata of Automata Theory

Answer»

Correct option is (C) Same NUMBER of states as well as transitions

The EXPLANATION is: TWO states are said to be equivalent if and only if they have same number of states as well as transitions.

70.

Mealy and Moore machine can be categorized as:(a) Inducers(b) Transducers(c) Turing Machines(d) Linearly Bounder AutomataThe question was asked in examination.The query is from Mealy Machine topic in section Finite Automata of Automata Theory

Answer»

The correct choice is (B) TRANSDUCERS

For explanation I WOULD say: They are collectively KNOWN as Transducers.

71.

Moore Machine is an application of:(a) Finite automata without input(b) Finite automata with output(c) Non- Finite automata with output(d) None of the mentionedI have been asked this question by my school teacher while I was bunking the class.My question is based upon Moore Machine topic in division Finite Automata of Automata Theory

Answer»

The CORRECT choice is (B) Finite AUTOMATA with output

Explanation: Finite automaton with an output is categorize DIN TWO parts: Moore M/C and Mealy M/C.

72.

The number of elements in the set for the Language L={xϵ(∑r) *|length if x is at most 2} and ∑={0,1} is_________(a) 7(b) 6(c) 8(d) 5The question was posed to me during an online interview.My query is from Finite Automata-Introduction topic in section Finite Automata of Automata Theory

Answer»

The correct choice is (a) 7

Easiest explanation: ∑r= {1,0} and a KLEENE* OPERATION WOULD LEAD to the following set=COUNT{ε,0,1,00,11,01,10} =7.

73.

Complement of a DFA can be obtained by(a) making starting state as final state.(b) no trival method.(c) making final states non-final and non-final to final.(d) make final as a starting state.I have been asked this question in an interview for internship.This question is from Union, Intersection & Complement topic in section Finite Automata of Automata Theory

Answer» RIGHT ANSWER is (c) making final STATES non-final and non-final to final.

Easiest explanation: STRING accepted in previous DFA will not be accepted and non accepting string will be accepted .
74.

Number of states require to simulate a computer with memory capable of storing ‘3’ words each of length ‘8’.(a) 3 * 2^8(b) 2^(3*8)(c) 2^(3+8)(d) None of the mentionedI got this question during an online exam.Origin of the question is Finite Automata in chapter Finite Automata of Automata Theory

Answer»

Correct choice is (b) 2^(3*8)

The EXPLANATION is: 2^(m*n) states REQUIRES .

75.

It is less complex to prove the closure properties over regular languages using:(a) NFA(b) DFA(c) PDA(d) Can’t be saidThis question was posed to me in an interview for job.This is a very interesting question from Applications of NFA in division Finite Automata of Automata Theory

Answer» CORRECT CHOICE is (a) NFA

Easy EXPLANATION: NONE.
76.

If L is a regular language, L^c and L^r both will be:(a) Accepted by NFA(b) Rejected by NFA(c) One of them will be accepted(d) Cannot be saidI have been asked this question in homework.I want to ask this question from The Language of NFA topic in division Finite Automata of Automata Theory

Answer»

The correct choice is (a) ACCEPTED by NFA

The BEST I can explain: If L is a regular Language, L^c and L^rboth are regular even.

77.

Which of the following is an application of Finite Automaton?(a) Compiler Design(b) Grammar Parsers(c) Text Search(d) All of the mentionedThis question was addressed to me in homework.Question is taken from Equivalence of NFA and DFA in portion Finite Automata of Automata Theory

Answer»

The correct choice is (d) All of the mentioned

Explanation: There are MANY applications of FINITE AUTOMATA, mainly in the field of COMPILER Design and Parsers and Search Engines.

78.

What is the relation between DFA and NFA on the basis of computational power?(a) DFA > NFA(b) NFA > DFA(c) Equal(d) Can’t be saidThis question was addressed to me in exam.My enquiry is from Extended Transition Function topic in portion Finite Automata of Automata Theory

Answer»

Correct option is (c) Equal

For explanation: DFA is SAID to be a SPECIFIC case of NFA and for every NFA that exists for a given language, an EQUIVALENT DFA also exists.

79.

Language of finite automata is.(a) Type 0(b) Type 1(c) Type 2(d) Type 3This question was posed to me by my school teacher while I was bunking the class.I'd like to ask this question from Finite Automata topic in chapter Finite Automata of Automata Theory

Answer» CORRECT OPTION is (d) Type 3

To EXPLAIN I would SAY: According to Chomsky classification.
80.

Transition function maps.(a) Σ * Q -> Σ(b) Q * Q -> Σ(c) Σ * Σ -> Q(d) Q * Σ -> QI got this question during an interview for a job.This intriguing question comes from Finite Automata topic in chapter Finite Automata of Automata Theory

Answer» CORRECT option is (d) Q * Σ -> Q

To elaborate: Inputs are state and input string OUTPUT is STATES.
81.

The O/P of Mealy machine can be represented in the following format:(a) Op(t)= δ(Op(t))(b) Op(t)= δ(Op(t)i(t))(c) Op(t): ∑(d) None of the mentionedI got this question in an international level competition.This intriguing question originated from Mealy Machine in section Finite Automata of Automata Theory

Answer» RIGHT OPTION is (b) Op(t)= δ(Op(t)i(t))

Best explanation: The output of MEALY machine depends on the present state as well as the input to that state.
82.

State true or false?(a) Statement: An NFA can be modified to allow transition without input alphabets, along with one or more transitions on input symbols.(b) True(c) FalseThis question was posed to me at a job interview.I would like to ask this question from Finite Automata with Epsilon Transition in section Finite Automata of Automata Theory

Answer»

The CORRECT choice is (a) Statement: An NFA can be modified to allow transition without input ALPHABETS, along with one or more TRANSITIONS on input SYMBOLS.

For explanation: It is POSSIBLE to construct an NFA with ε-transitions, presence of no input symbols, and that is called NFA with ε-moves.

83.

(a ^ 5b ^ 5)* is example of ________(a) Type 0 language(b) Type 1 language(c) Type 2 language(d) Type 3 languageThis question was addressed to me in exam.I need to ask this question from Union, Intersection & Complement topic in portion Finite Automata of Automata Theory

Answer»

The CORRECT CHOICE is (d) TYPE 3 language

The best I can EXPLAIN: It is a regular expression.

84.

Let L be a language whose FA consist of 5 acceptance states and 11 non final states. It further consists of a dumping state. Predict the number of acceptance states in L^c.(a) 16(b) 11(c) 5(d) 6This question was posed to me in my homework.Question is taken from Applications of DFA topic in section Finite Automata of Automata Theory

Answer»

The CORRECT choice is (a) 16

Explanation: If L leads to FA1, then for L^c, the FA can be OBTAINED by exchanging the FINAL and non-final states.

85.

The construction time for DFA from an equivalent NFA (m number of node)is:(a) O(m^2)(b) O(2^m)(c) O(m)(d) O(log m)I had been asked this question in an online interview.I want to ask this question from Non Deterministic Finite Automata in portion Finite Automata of Automata Theory

Answer» CORRECT OPTION is (b) O(2^m)

The BEST explanation: From the CODED NFA-DFA conversion.
86.

Extended transition function is .(a) Q * Σ* -> Q(b) Q * Σ -> Q(c) Q* * Σ* -> Σ(d) Q * Σ -> ΣThis question was addressed to me during an interview for a job.I'd like to ask this question from Finite Automata in section Finite Automata of Automata Theory

Answer»

The correct answer is (a) Q * Σ* -> Q

For EXPLANATION I WOULD say: This takes single state and STRING of input to PRODUCE a state.

87.

From the given table, δ*(q0, 011) =?(a) {q0}(b) {q1} U {q0, q1, q2}(c) {q2, q1}(d) {q3, q1, q2, q0}I have been asked this question in exam.I want to ask this question from Extended Transition Function topic in section Finite Automata of Automata Theory

Answer»

Correct choice is (B) {Q1} U {q0, q1, q2}

To explain: δ*(q0,011) = Urϵδ*(q0,01) δ (r, 1) = {q0, q1, q2}.

88.

How many languages are over the alphabet R?(a) countably infinite(b) countably finite(c) uncountable finite(d) uncountable infiniteI have been asked this question in an international level competition.This interesting question is from The Language of DFA topic in portion Finite Automata of Automata Theory

Answer»

Right answer is (d) UNCOUNTABLE infinite

Easy EXPLANATION: A language over an alphabet R is a SET of strings over A which is uncountable and infinite.

89.

Can a DFA recognize a palindrome number?(a) Yes(b) No(c) Yes, with input alphabet as ∑*(d) Can’t be determinedThe question was posed to me in homework.Question is from Deterministic Finite Automata-Introduction and Definition topic in division Finite Automata of Automata Theory

Answer»

Correct answer is (b) No

Explanation: Language to ACCEPT a palindrome number or STRING will be non-regular and thus, its DFA cannot be obtained. Though, PDA is POSSIBLE.

90.

The following mealy machine outputs which of the following?(a) 9’s Complement(b) 2’s Complement(c) 1’s Complement(d) 10’s ComplementThis question was addressed to me by my college director while I was bunking the class.My question is from Mealy Machine topic in division Finite Automata of Automata Theory

Answer» CORRECT option is (b) 2’s Complement

For EXPLANATION: The input can be taken in form of a binary STRING and can be verified.
91.

Regular expression for all strings starts with ab and ends with bba is.(a) aba*b*bba(b) ab(ab)*bba(c) ab(a+b)*bba(d) All of the mentionedThis question was addressed to me during a job interview.This interesting question is from Finite Automata in chapter Finite Automata of Automata Theory

Answer» CORRECT choice is (c) ab(a+b)*bba

Best EXPLANATION: STARTS with ab then any number of a or b and ends with bba.
92.

Which among the following is not notated as infinite language?(a) Palindrome(b) Reverse(c) Factorial(d) L={ab}*This question was addressed to me in an online interview.The question is from Simpler Notations topic in chapter Finite Automata of Automata Theory

Answer»

Correct ANSWER is (C) Factorial

The best I can EXPLAIN: Factorial, here is the most appropriate non-infinite domain. Otherwise, PALINDROME and reverse have infinite DOMAINS.

93.

Regular sets are closed under union,concatenation and kleene closure.(a) True(b) False(c) Depends on regular set(d) Can’t sayI got this question in an interview for job.I'd like to ask this question from Union, Intersection & Complement in section Finite Automata of Automata Theory

Answer»

Right choice is (a) True

To ELABORATE: REGULAR SETS are closed under these three OPERATION.

94.

ε- closure of q1 in the given transition graph:(a) {q1}(b) {q0, q2}(c) {q1, q2}(d) {q0, q1, q2}I had been asked this question in an interview.I want to ask this question from Finite Automata with Epsilon Transition topic in chapter Finite Automata of Automata Theory

Answer»

Right choice is (c) {Q1, q2}

Best EXPLANATION: ε-closure is defined as the set of states being REACHED through ε-transitions from a starting STATE.

95.

The major difference between Mealy and Moore machine is about:(a) Output Variations(b) Input Variations(c) Both(d) None of the mentionedThis question was posed to me in examination.My query is from Mealy Machine topic in section Finite Automata of Automata Theory

Answer»

The correct choice is (a) OUTPUT Variations

To explain: MEALY and Moore machine vary over how the outputs depends on PRIOR one (TRANSITIONS) and on the latter one(states).

96.

The output alphabet can be represented as:(a) δ(b) ∆(c) ∑(d) None of the mentionedI had been asked this question in an international level competition.Enquiry is from Moore Machine in portion Finite Automata of Automata Theory

Answer» CORRECT option is (b) ∆

The best I can explain: Source-The tuple definition of MOORE and mealy MACHINE comprises one NEW member i.e. OUTPUT alphabet as these are finite machines with output.
97.

A binary string is divisible by 4 if and only if it ends with:(a) 100(b) 1000(c) 1100(d) 0011I got this question in an online quiz.The above asked question is from Applications of DFA in portion Finite Automata of Automata Theory

Answer»

The correct answer is (a) 100

Explanation: If the STRING is DIVISIBLE by four, it surely ENDS with the substring ‘100’ while a binary string divisible by 2 would surely end with the substring ‘10’.

98.

A ___________ is a substitution such that h(a) contains a string for each a.(a) Closure(b) Interchange(c) Homomorphism(d) Inverse HomomorphismI got this question in an interview.Question is from Union, Intersection & Complement topic in division Finite Automata of Automata Theory

Answer»

The CORRECT OPTION is (c) Homomorphism

To explain I would say: This OPERATION REPLACE using a FUNCTION .

99.

If n is the length of Input string and m is the number of nodes, the running time of DFAis x that of NFA.Find x?(a) 1/m^2(b) 2^m(c) 1/m(d) log mThis question was posed to me by my school teacher while I was bunking the class.I need to ask this question from Non Deterministic Finite Automata in division Finite Automata of Automata Theory

Answer»

The correct OPTION is (a) 1/m^2

Explanation: Running time of DFA: O(N) and Running time of NFA =O(m^2n).

100.

In mealy machine, the O/P depends upon?(a) State(b) Previous State(c) State and Input(d) Only InputThis question was posed to me in an interview.I'd like to ask this question from Mealy Machine topic in section Finite Automata of Automata Theory

Answer»

The correct answer is (c) State and Input

For EXPLANATION I would say: DEFINITION of MEALY MACHINE.