FACULTY OF SCIENCE
FINAL EXAMINATION
COMPUTER SCIENCE COMP 330
Theoretical Aspects of Computer Science
Examiner: Prof. Prakash Panangaden 11th December 2009
Associate Examiner: Prof. Laurie Hendren 2 pm to 5 pm
Instructions:
This exam has 6 questions. Ple
M G _ ' December 2814
{sf/f . C Final Examination
FACULTY OF SCIENCE McGill University
FINAL EXAll/HNATION for Fall 2014
COMPUTER SCIENCE COMP 330
Theory of Computing
Examiner: Prof. Prakash Panangaden ‘ 16th December 2014
Associate Examiner: Prof. Ha
COMP 330: Assignment 4
Solutions
Prakash Panangaden
November 17, 2015
Question 1[20 points] Consider the grammar
S aSb|bSa|SS|.
What set is generated by this grammar? Prove your answer. You need to say the language consists
of all string of such and such
CSU390 Theory of Computation
Fall 2004
Pumping Lemma for CFLs
October 15, 2004
The Pumping Lemma for Context-free Languages: An Example
Claim 1 The language
wwR w | w cfw_0, 1
is not context-free.
Proof: For the sake of contradiction, assume that the lan
COMP 330 Autumn 2015
Assignment 2
Solutions
Prakash Panangaden
Question 1[20 points] Give regular expressions for the following languages over
cfw_a, b:
1. cfw_w|w begins and ends with an a. Solution: a + a(a + b) a.
2. cfw_w| every odd position is a b. S
Basic Logic and Mathematical Structures
for COMP 330
Prakash Panangaden
McGill University
3rd September 2015
These notes are not meant as a substitute for learning the subject of the
title properly. They are meant to make sure we have some basic vocabular