hw3 - < bitstring> mod 7 = 0 4 The set of all strings...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
CS 415 Compilers: Problem Set 3 Due date: Wednesday, February 24, in recitation Problem 1 – DFA Give a DFA for the following languages over the aphabet { 0, 1 } : 1. The set of all strings with an odd number of 0’s and an even number of 1’s . 2. The set of all strings beginning with a 1 which, interpreted as the binary representation of an integer, is congruent to zero modulo 4, i.e., < bitstring > mod 4 = 0. 3. The set of all strings beginning with a 1 which, interpreted as the binary representation of an integer, is congruent to zero modulo 7, i.e.,
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: < bitstring > mod 7 = 0. 4. The set of all strings beginning with a 1 which, interpreted as the binary representation of an integer, are greater than 999. Problem 2 – NFA and DFA 1. Construct a nondeterministic finite automaton (NFA) for the regular expression ( ab * c ) | d using Thompson’s Construction Algorithm. 2. Convert your NFA with ± transitions into a DFA using the subset construction. 3. Show that your DFA is minimal or, if it is not minimal, give the minimal DFA....
View Full Document

This note was uploaded on 10/29/2010 for the course CS 198:415 taught by Professor Kremer,u. during the Spring '10 term at Rutgers.

Ask a homework question - tutors are online