We are here with you hands in hands to facilitate your learning & don't appreciate the idea of copying or replicating solutions. Read More>>

www.vustudents.ning.com

 www.bit.ly/vucodes + Link For Assignments, GDBs & Online Quizzes Solution www.bit.ly/papersvu + Link For Past Papers, Solved MCQs, Short Notes & More

Dear Students! Share your Assignments / GDBs / Quizzes files as you receive in your LMS, So it can be discussed/solved timely. Add Discussion

# CS402 Assignment No 01 Fall 2019 Solution & Discussion Due Date: 15-11-2019

CS402 Assignment No 01 Fall 2019 Solution & Discussion Due Date: 15-11-2019

CS402 Theory of Automata Assignment 1 Solution Fall 2019

 Assignment No. 01Semester: Fall 2019Theory of Automata – CS402 Total Marks: 20 Due Date: November 15, 2019 Objectives: Objective of this assignment is to assess the understanding of students about the concept of languages, regular expressions and finite automata. Instructions: Please read the following instructions carefully before submitting assignment: You should consult the recommended books, PowerPoint slides and audio lectures to clarify your concepts. You are supposed to submit your assignment in .doc format. Any other formats like scan images, PDF, zip, rar and bmp etc will not be accepted. It should be clear that your assignment will not get any credit if: ·       The assignment is submitted after due date. ·       The assignment is copied from Internet or from any other student. ·       The submitted assignment does not open or file is corrupt.   Note: No assignment will be accepted after the due date through email in any case (load shedding, server down, internet malfunctioning etc.). It is recommended to upload solution file at least two days before its closing date. For any query about the assignment, contact at CS402@vu.edu.pk   Question:                                                                                                              Marks = 20 Q1. Show that the following pairs of regular expressions define the same language over the alphabet   L = {a, b}.   (i) (ab)*a         and    a(ba)* (ii) (a* + b)*    and    (a + b)* (iii) (a* + b*)* and    (a + b)*                                                                                                                                      [9 marks = 3*3] Q2. Develop a regular expression for the following language over the alphabet P = {a, b} such that it accepts all strings in which the letter b is never tripled. This means that no word contains the substring bbb.                                                                                                                                          [5 marks]   Q3. Develop a regular expression for the following language over the alphabet P = {a, b} such that it accepts all strings all words in which a is tripled or b is tripled, but not both. This means each word contains the substring aaa or the substring bbb but not both.                                                 [ 6 marks]

+ How to Join Subject Study Groups & Get Helping Material?

+ How to become Top Reputation, Angels, Intellectual, Featured Members & Moderators?

+ VU Students Reserves The Right to Delete Your Profile, If?

Views: 3379

.

+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)

+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)

### Replies to This Discussion

Our main purpose here discussion not just Solution

Discussed & be touched with this discussion. After discussion a perfect solution will come in a result at the end.

P.S:    Please always try to add the discussion in proper format title like “CS101 Assignment / GDB No 01 Solution & Discussion Due Date: ___________”

Then copy Questions from assignment file and paste in Discussion.

http://bit.ly/vucodes (For Assignments, GDBs & Online Quizzes Solution)

http://bit.ly/papersvu (For Past Papers, Solved MCQs, Short Notes & More)

***

# CS 402 Assignment 1 solution fall 2019

CS402 Assignment 1 Solution Fall 2019
Q1. Show that the following pairs of regular expressions define the same language over the alphabet
L = {a, b}.
(i) (ab)*a         and    a(ba)*
(ii) (a* + b)*    and    (a + b)*
(iii) (a* + b*)* and    (a + b)*
Solution:
Since the strings generated by language (ab)*a and a(ba)* define the same strings ending in a hence both  RE define the same language.
Both RE define the same language of all string containing any number of a’s and b’s
Since (a* + b*)*  and (a + b)* generate all string containing any number of a’s and b’s hence both RE define the same  language.
Q2. Develop a regular expression for the following language over the alphabet P = {a, b} such that it accepts all strings in which the letter b is never tripled. This means that no word contains the substring bbb.
Answer: since we need to define RE for a language that have strings like {Λ, abb,abba, aabbaa,…}
Hence the RE for this language would be (a * +  bb)*
Q3. Develop a regular expression for the following language over the alphabet P = {a, b} such that it accepts all strings all words in which a is tripled or b is tripled, but not both. This means each word contains the substring aaa or the substring bbb but not both.
Answer: since we need to develop a RE for a language that have strings like {aaab, bbbaa, aaabb}
Hence the required RE for this language would be (aaa+ + b) + (bbb+ + a)

CS402-Assignment-1-Solution-Fall-2019_VU_Ning

CS402-Assignment-1-Solution-Fall-2019_VU_Ning

CS402 Assignment 1 Complete & Correct Solution Fall 2019

with Full Explanations

✧Ｆｏｏｄｉｅ✧ Direct link allowed nai hai .... kitni bar ap ku bata chuka hun ...

CS402 One more solution

CS402_Assignment#01_Solution_VU_Ning

CS402 Assignment No 1 Solution Sample Preview Fall 2019 - Theory of Automata-1

********

CS402_Solution_Assignment_01_Fall_2019_Ning

CS402_Solution_Assignment_01_Fall_2019_Ning

## Latest Activity

Rana Mustafa Zohaib, Mudaser Naik, Natiq and 14 more joined Virtual University of Pakistan
2 hours ago
٢٣ دن posted a discussion

### ......آج کل کے بچے یہ کبھی نہیں جان پائیں گے کہ

3 hours ago
Meg updated their profile
4 hours ago
Muhammad Sami (MOSCM) added a discussion to the group MGMT614 Supply Chain Management

### Past Papers

4 hours ago
Muhammad Sami (MOSCM) joined + M.Tariq Malik's group

### MGMT614 Supply Chain Management

4 hours ago
Abdullah joined + M.Tariq Malik's group

### CS101 Introduction to Computing

6 hours ago
+ Տehɑr Ƙհɑղ + updated their profile
6 hours ago
+ M.Tariq Malik's 14 discussions were featured
7 hours ago
+ M.Tariq Malik added a discussion to the group CS314 Introduction to Cellular Networks

7 hours ago

1