0% found this document useful (0 votes)
30 views7 pages

Question Bank

QB

Uploaded by

anshulsarawagi
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)
30 views7 pages

Question Bank

QB

Uploaded by

anshulsarawagi
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/ 7

SAGAR INSTITUTE OF SCIENCE & TECHNOLOGY(SISTec)

DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING

BRANCH CSE QUESTION BANK


July -Dec
SESSION
2024

NAME OF THE FACULTY: ANSHUL SARAWAGI


SUBJECT/CODE : CS 501 THEORY OF COMPUTATION

UNIT-1

Bloom’s Course
Q
QUESTIONS Taxonomy Outcome
No.
Level

1. 3(Apply) CO1

Convert following Mealy machine into equivalent Moore machine.

2.
3(Apply) CO1
3. Construct a Moore Machine that generates an output ‘A’ if string endswith 10 and 3(Apply) CO1
generates output ‘B’ if string ends with 11 otherwise generates output ‘C’.
Convert the given Mealy machine into its equivalent Moore machine.

4. 3(Apply) CO1

Convert following Moore machine into equivalent Mealy machine.

5. 3(Apply) CO1

Construct an equivalent Moore Machine for the given Mealy Machine

6.
3(Apply) CO1

7. Write the short note on finite state machine. 1(Remember) CO1

8. Differentiate between transition graph and transition matrix. 2(Understand) CO1

Define the following with example 1(Remember) CO1


9.
(i) Mealy machine
(ii) Moore machine.
10. Define Finite State Machine formally with the help of 6-tuples. 1(Remember) CO1

11. Design a DFA to accept the string of (0,1) not ending with the string 01. 5(Create) CO1
UNIT-II

Bloom’s Course
Q
QUESTIONS Taxonomy Outcome
No.
Level
1. Design a FSM for binary input which is divisible by 3. 3(Apply) CO2

Construct DFA for the following language: 3(Apply) CO2


2. L(M)={W∈ (0,1)*│W has neither ‘00’ nor ‘11’ as a substring}.

3. Construct a minimal DFA that accepts all strings of 0’s and 1’s such that number 3(Apply) CO2
of 0’s divisible by 5 and number of 1’s divisible by 3.
Convert into minimum state automata for the given DFA.

4. 3(Apply)
CO2

Convert the given NFA to equivalent DFA

CO2

5. 3(Apply)

Find €-closure for the following NFA with €.

6. 3(Apply)
CO2

Construct DFA for the following regular expressions. CO2


7. i. 1(0+1)*+(0+1)*1 3(Apply)
ii. 0(0+1)*0+1(0+1)*1

Construct regular expression for the given finite automata. CO2

8. 3(Apply)

9. Show that L={0m1n0m+n | m, n>=1} is not a regular language. 3(Apply) CO2


10. Write a short note on two-way Finite Automata. 1(Remember) CO2

Convert the given NFA to equivalent DFA

CO2
11. 3(Apply)
UNIT-III

Bloom’s Course
Q
QUESTIONS Taxonomy Outcome
No.
Level
Find the context free grammar for the following language- 3(Apply)
(with n>=0, m>=0, k>=0) CO3
1.
L = { aⁿ bmck | n=m or m<=k }
L= { a2nbc | n>=1}
Consider the following productions-
S aAS / a CO3
2. 3(Apply)
A SbA / SS / ba
Find out LMD, RMD & construct a Parse Tree for the string aabbaa
Transform the grammar with productions-
3. A  BAB / B / ε 3(Apply)
B 00 / ε CO3
into Chomsky Normal form.
Convert the CFG into GNF-
4. A BC 3(Apply) CO3
B CA / b
C AB / a
Simplify the given CFG
SaSB/aA/bB
5. 3(Apply) CO3
AaA/ ε
BbB/ ε

Convert the following CFG into CNF.


6. SbA/aB 3(Apply) CO3
AbAA/aS/a
BaBB/bS/b
7. Construct a regular grammar G generating the regular set represented by 3(Apply) CO3
P = 0*1(0+1)*
8. Define Context Free Grammar Formally. 1(Remember) CO3

Consider the following grammar.


S (L)/a
9. 3(Apply) CO3
LL,S/S
((a,a),(a,a)) Construct LMD & RMD

Write Regular grammar for the following Regular Expression:


10. i) ab*b 2(Understand)
CO3
ii) a(a+b)*b
UNIT-IV

Bloom’s Course
Q
QUESTIONS Taxonomy Outcome
No.
Level
Construct the PDA that accepts {WCWR | W ≡ (0+1)*} by empty stack, where 3(Apply) CO4
1.
WR represents the reverse of W?
2. Construct the PDA that accepts {WWR | W ≡ (0+1)*} 3(Apply) CO4

Construct the PDA equivalent to the following grammar-


3. S aAA 3(Apply)
CO4
A aS / bS / a
Give the CFG generating the language accepted by the following PDA:
M=({q0,q1},{0,1}, {z0,x}, q0, z0, φ, δ)
CO4
4. 2(Understand)
δ (q0, 0, z0) = ( q0, Xz0) δ (q1, 1, X) = ( q1, ε)
δ (q0, 0, X) = ( q0, XX) δ (q1,ε, X) = ( q1, ε)
δ (q0, 1, X) = ( q1, ε) δ (q1,ε, z0) = ( q1, ε)
Construct PDA for the following set-
5. L = {an b2n | n ≥ 1} 3(Apply)
L = {a2n bn| n ≥ 1} CO4

6. Construct PDA for the language: 3(Apply) CO4


L = {am bm+ncn| m, n ≥ 1}
7. Define Push Down Automata (PDA) formally. 1(Remember) CO4

8. Give the difference between PDA with ‘Empty stack’ and ‘Final state’ with 2(Understand) CO4
example.
9. Write short note on decision algorithms for Context free languages? 1(Remember) CO4

Explain the difference between Deterministic PDA and Non-Deterministic PDA


10. 2(Understand)
with example. CO4
UNIT-V

Bloom’s Course
Q
Taxonomy Outcome
No.
QUESTIONS Level
All natural numbers are either even or odd. Construct a Turing machine that
computes the parity function for natural numbers, i.e. that computes:

0, if n is even 3(Apply)
1. CO5
F(n) =

1, if n is odd
Design a Turing machine to recognize all strings consisting of even number of 3(Apply) CO5
2.
1’s.
3. Design a Turing machine to accept the language. 3(Apply) CO5
L={WWR | W ≡ (0+1)*}
4. Design a Turing machine to accept the language. 3(Apply) CO5
L={WcWR | W ≡ (0+1)*}
Write a brief note on:
5. i. Universal Turing machine. 1(Remember)
ii. Church –Turing hypothesis CO5
iii. P & NP Class problems

Design a Turing machine to recognize all strings consisting of equal number of 3(Apply) CO5
6.
1’s and 0’s.
7. Define Turing machine and its parameters. 1(Remember) CO5

8. Explain multi-tape and multi-head Turing machine. 2(Understand) CO5

Design a Turing machine to recognize all strings consisting of equal number of 3(Apply) CO5
9.
1’s and 0’s.
Prove that
i. The union of two recursive languages is recursive.
10. ii. If a language L and its complement Ā are both recursively enumerable 4(Analyze) CO5
then Ā
is recursive.

You might also like