0% found this document useful (0 votes)
151 views8 pages

CS301 Automata Exam Spring 2016

This document contains an exam for a Theory of Automata course given at the National University of Computer and Emerging Sciences. The exam contains 6 multiple choice questions worth a total of 50 marks. The questions cover topics like recursive definitions of languages, regular expressions, converting between finite automata models like regular grammars, non-deterministic finite automata, and deterministic finite automata. The exam instructions specify that students must show their work and cannot ask clarifying questions.

Uploaded by

Amna Sumbal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
151 views8 pages

CS301 Automata Exam Spring 2016

This document contains an exam for a Theory of Automata course given at the National University of Computer and Emerging Sciences. The exam contains 6 multiple choice questions worth a total of 50 marks. The questions cover topics like recursive definitions of languages, regular expressions, converting between finite automata models like regular grammars, non-deterministic finite automata, and deterministic finite automata. The exam instructions specify that students must show their work and cannot ask clarifying questions.

Uploaded by

Amna Sumbal
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 8

National University of Computer and Emerging Sciences

School of Computing Spring 2016 Islamabad Campus

Serial No:
CS301-Theory of Automata
Sessional I
Total Time: 60 minutes
Saturday, Sept 24, 2016 Total Marks: 50
Course Instructor
Dr. Aftab Maroof, Dr Waseem Shehzad, Dr Labiba ________________
Signature of Invigilator
Fahad, Ms. Mehreen Alam

_____________________________________________ _____________________
Student Name Roll No Section Signature

DO NOT OPEN THE QUESTION BOOK OR START UNTIL INSTRUCTED.


Instructions:
1. In all questions, use the algorithms studied in the class and show all steps to get full credit.
2. Understanding the question paper is also part of the exam, so do not ask any clarification.
3. The question paper is printed on both sides of the pages.
4. Attempt all questions on the same sheets/pages and within the space provided with each
question. You may lose marks if you write in extra space.
5. Make sure that this question paper contains eight (08) pages including title page. Be brief,
smart and efficient!
6. Use permanent ink pens only. Any part done using soft pencil will not be marked and cannot
be claimed for rechecking.

Question 1 2 3 4 5 6 Total

Marks
Obtained
Total
5 10 10 5 10 10 50
Marks

Vetted By: _____________________________Vetter Signature: _____________________

1
National University of Computer and Emerging Sciences
School of Computing Spring 2016 Islamabad Campus

Q1. [5 pts] Give recursive definition of language defined over alphabet Σ = {a, b}, having all
strings not ending with aa or bb.

Q2. [5+5 =10 pts]Write regular expression for each of the following language defined over
alphabet Σ ={a, b}
a. Language of strings not having bb or aa at any place

b. Language of all strings having number of b’s in multiples of 2

2
National University of Computer and Emerging Sciences
School of Computing Spring 2016 Islamabad Campus
Q3. [10 pts] Convert the following GTG to a regular expression. Show all the steps.

3
National University of Computer and Emerging Sciences
School of Computing Spring 2016 Islamabad Campus

Q4. [5 pts] Convert the regular expression ( (ab)*b )* to NFA.

4
National University of Computer and Emerging Sciences
School of Computing Spring 2016 Islamabad Campus

Q5. [10 pts] Convert the following NFA to the corresponding DFA. Show the resultant transition table
and the state diagram.

5
National University of Computer and Emerging Sciences
School of Computing Spring 2016 Islamabad Campus

6
National University of Computer and Emerging Sciences
School of Computing Spring 2016 Islamabad Campus

Q6. [ 10pts ] Minimize the following (copy diagram from the book) DFA. Show the resultant
state diagram and transition table.

7
National University of Computer and Emerging Sciences
School of Computing Spring 2016 Islamabad Campus

You might also like