0% found this document useful (0 votes)
17 views14 pages

Regular Expression - DPP 01 Discussion Notes

Uploaded by

Sonu Tyagi
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)
17 views14 pages

Regular Expression - DPP 01 Discussion Notes

Uploaded by

Sonu Tyagi
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/ 14

CS & IT

ENGINEERING
THEORY OF COMPUTATION

Regular Expressions
DPP - 01 Discussion Notes By- Venkat sir
[NAT]
#Q. The possible number of DFA with 2 states X,Y over the alphabet {a, b} where
X is always initial state ?
[NAT]
#Q. The possible number of DFA with 2 states X,Y over the alphabet {a, b} where
X is always initial state , that accepts empty language?
[NAT]
#Q. The possible number of DFA with 2 states X,Y over the alphabet {a, b} where
X is always initial state , that accepts complete language?
[MCQ]
Consider the DFA ,M with states Q={0,1,2,3,4}, input alphabet Ʃ = {0,1} start
state 0, final state 0 and transition function δ(q,i)=|q2 –i| mod 5 q ϵ Q, input
alphabets are {0,1}

#Q. The above DFA, M accepts all binary strings containing


A even number of l's

B odd number of 1’s

C even number of O's

odd number of 0’s


D
[MCQ] Consider the DFA ,M with states Q={0,1,2,3,4}, input alphabet Ʃ = {0,1} start state 0, final state
0 and transition function δ(q,i)=|q –i| mod 5 q ϵ Q, input alphabets are {0,1}
2

#Q. The number of states in the minimal finite automata ,which is equivalent to
M is

A 1

B 2

C 3

D 4
[MCQ]
#Q. The regular expression for the language recognized by the following finite
automata is?

A (0 + 1)* B 0(0 + 1)*1

C 0*1* D 0*(0 + 1)*1 *


[MCQ]
#Q. Choose the regular language from the following

A L = {x/x  (a + b)*} and is even length palindrome

B L = {an/ n 1}

C L = {an b2n/ n 1}

D none
[MCQ]
#Q. Which of the following regular expression represents all strings of a’s and
b’s where the length of the string is at most ‘n’ is

A (a + b)n

B (a+b)n(a+b)*

C (a + b + Ɛ)n

D None of the above


[MCQ]
#Q. Which of the following pair of regular expressions are not equal

A (r*)* and (r*)*

B (r + Ɛ)* and r*

C (rr + Ɛ)* and r*

D None of the above


[MCQ]
#Q. Consider the language S*, where S is all strings of a’s and b’s with odd
length. The other description of this language is.

A All strings of a’s and b’s

B All even length strings of a’s and b’s

C All odd length strings of a’s and b’s

D None of the above


[MCQ]
#Q. Let r= (1 + 0)*, s = 11 *0 and t = 1*0 be three regular expressions. Which
one of the following is true?

A L(s) ⸦ L(r) and L(s) ⸦ L(t)

B L(r) ⸦ L(s) and L(s) ⸦ L(t)

C L(t) ⸦ L(s) and L(s) ⸦ L(r)

D None of the above


THANK - YOU

You might also like