0% found this document useful (0 votes)
16 views10 pages

CS 24F Automata Mid2+Student Solution

This document is an exam paper for the Theory of Automata course (CS-3005) at FAST School of Computing, detailing three questions related to formal languages and automata. It includes tasks such as proving language membership, designing context-free grammars, and converting machines between types. The exam is scheduled for November 5, 2024, with a total of 60 marks available.

Uploaded by

fawad.sidd17
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)
16 views10 pages

CS 24F Automata Mid2+Student Solution

This document is an exam paper for the Theory of Automata course (CS-3005) at FAST School of Computing, detailing three questions related to formal languages and automata. It includes tasks such as proving language membership, designing context-free grammars, and converting machines between types. The exam is scheduled for November 5, 2024, with a total of 60 marks available.

Uploaded by

fawad.sidd17
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/ 10

Natic

Theory
of
Automata
CS-3005
courseInstructor
(s):
Mehreen
Fahad, Dr.
Mehmood, and
ntLabiba
Ms. Tajwar
Ms. MaryamShahbaz
alam,
G,J,K
D,E,H, Roll No
ectionsA,B,C, Course Section Student
Sessional-1|Exam Signature
otal Time (Hrs): 1
otal Marks: 60
btalQuestions: 3

ate: Nov 5,2024


ructions : Attempt all questions on answer sheet and properly
marked. mention the guestion number, otherwise it will not
ot write below this line.
empt all the questions.
LO1:Identify formal language classes and prove language membership
estion 1:Show that L= fa"b'ctk;n>-0. k>=0: is not regular. by using properties!
the pumping lete
rem. [10 Marks]
0 2: Differentiate and manipulate formal descrintions of languages, automata a
mmars with focus on non-regular, regular, context-free languages using automata (DrA,
A, PDA)) and Turing Machines.]
estion 2: [30Marks]

a. [10 Marks] Design cfg for the language L={a'n b'n a mb^t a^t b^m |n,m>=0 ,t0}
b. [10 Marks] Design cfg for equal number of a's and b's in string.
C. [10 Marks] Convert the following NFA to DFA? Show the complete working.

S1

Start So S

Sessional-| Exam, Fall 2024 FAST School of Computing Page 1 of


National University of Computer and Emerging SCiences
Islamabad Campus

and disprove theorems establishing key properties of formal languages and


(CLO 3: Prove
automata |
[20Marks]
Question 3:
into Moore Machine. Show the Compe
a. 10 Marks] Convert the following Mealy Machine
vworking 1/o

ojo 1/2 o/1

b. [10Marks] Let rl and r2 be regular expressions and FA1 and FA2 be finite
automata that
accept exactly the languages defined by rl and r2 respectively. By applying
kleene's theorem,
build another FA that accepts all the words of the
language defined by rl+r2. Show the
complete working.
FA;
a, b b /a, b

Sessional-| Exam, Fall 2024 FAST School of


GuestemoA

To
can be any nuabat
Let

The aa bhcccc
Lotk Akvide into

L
Lett

aa bbe bbc ccc


As the string fain
aot soulan
Page No, 04

Questomtto
Ca)
L=iaban Sat

X aXb
2’ bztbt

CsSabSshas
S S a SS bs Sh SSasA
NEA to DEA
Transition table f iven
States

SSo

Tronsithon able ot Converted DFA:


States
So So Sa a
S

Sa S

So

SoSs.
/Part No.
Page No.06

Converted DEA

start

So55,S,
Ro

Page No,03

Qesto 03

olt

Stp 3i

o
Page No,04
Union ot

a,b

FA2

for FA transition table


Stetes a

+
Page No. 02

QPart No.

FA,tFA, FA

You might also like