Theory of Computation (3160704) MCQs

MCQs of Regular Languages and Finite Automata

Showing 21 to 30 out of 65 Questions
21.
What is the language generated by this regular expression? a(a+b)*a
(a) Always starts with b
(b) Can have any number of ba and ab
(c) Cannot have 2 b's together.
(d) Starts and end with same symbol
Answer:

Option (d)

22.
In some programming languages, an identifier is permitted to be a letter followed by any number of letters or digits. If L and D denotes the set of letters and digit respectively. Which of the following expression defines an identifier?
(a) (L + D) *
(b) (L.D) *
(c) L(L + D) *
(d) L(L.D) *
Answer:

Option (c)

23.
The regular expression corresponding to the language L where L = { x ϵ {0, 1}*|x ends with 1 and does not contain substring 00 } is:
(a) (1 + 01) * (1 + 01)
(b) (1 + 01) * 01
(c) (1 + 01) * (10 + 01)
(d) (10 + 01) * 01
Answer:

Option (a)

24.
(a + b*c) most correctly represents:
(a) (a +b) *c
(b) (a + (b*)).c
(c) (a)+((b)*.c)
(d) a+ ((b*).c)
Answer:

Option (b)

25.
If r and s are two regular expression then expression r+s is:
(a) Regular expression
(b) Regular language
(c) Union
(d) None of these
Answer:

Option (a)

26.
The finite automata is called NFA when there exists________ for a specific input from current state to next state
(a) Single path
(b) Multiple paths
(c) Only two paths
(d) None
Answer:

Option (b)

27.
Number of states require to accept string ends with 10
(a) 1
(b) 2
(c) 3
(d) Can’t be represented
Answer:

Option (c)

28.
There are ________ tuples in finite state machine (FA).
(a) 4
(b) 5
(c) 6
(d) Unlimited
Answer:

Option (b)

29.
Transition function of FA maps:
(a) Σ * Q Σ
(b) Q * Q Σ 
(c) Σ * Σ Q
(d) Q * Σ Q
Answer:

Option (d)

30.
Extended transition function is:
(a) Q * Σ*  Q
(b) Q * Σ  Q 
(c) Q* * Σ*  Σ
(d) Q * Σ  Σ
Answer:

Option (a)

Showing 21 to 30 out of 65 Questions