hw4sol - CSE 105 Introduction to the Theory of Comptuation...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
CSE 105: Introduction to the Theory of Comptuation Fall 2010 Problem Set 4 Instructor: Daniele Micciancio Due on: Wed. Nov 3, 2010 Problem 1 Use JFLAP to design Push Down Automata for the following language: The set of all strings over the alphabet { a,b } that contain an unequal number of a ’s and b ’s (in any order). The automaton first mark the bottom of the stack with a special symbol “x”. Whenever the stack contains only “x”, the automaton has read an equal number of “a” and “b”. The automaton keeps track of how many a’s and b’s have been read using the stack. The autmaton will be in state q 2 if it has read more a’s than b’s, and in state q 3 if is has read more b’s than a’s. Whenever the automaton has read the same number of a’s and b’s, it moves back to q 1 . Problem 2 Give a Context Free Grammar for the set of all strings over the alphabet { a,b } that are not palyndromes. The grammar has two variable symbols. T generates the set of all strings. S generates the strings that
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.
  • Spring '10
  • Mr.ElieNasr
  • Formal language, Context-free grammar, context free grammar, Theory of Comptuation, Daniele Micciancio

{[ snackBarMessage ]}

Page1 / 2

hw4sol - CSE 105 Introduction to the Theory of Comptuation...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online