CS 478 - Operating Systems - Spring 2007
Exam #2 Practice Problems


Loyola College > Department of Computer Science > Dr. James Glenn > CS 478 > Homework > Exam #2 Practice Problems

Due

Friday, March 30th at 1:00pm (not to hand in).

Solutions will be available.

Problem 0: Review old homeworks and exams.

Problem 1: Give a grammar that generates the same language as the regular expression (a + b)*(a* + (ba)*).

Problem 2: Give a pushdown automaton that accepts the language {anbm | m > n >= 0}. Show that your PDA accepts aabbb and bbbb and that it rejects aaab.

Problem 3: For each language given below either give a context free grammar for that language or prove that it is not context free.

Problem 4:

Problem 5: Determine whether the grammar implicitly defined by the following rules is ambiguous. Prove your answer. If the grammar is ambiguous, determine whether the language it generates is inherently ambiguous.

S → AB
A → aA
A → abA
A → ε
B → bB
B → abB
B → ε