Pages

Saturday 16 June 2012

Theory of Automata (CS402) Assignment no 4 Spring 2012 Idea Solution


Q1. Write down CFG of a language in which the number of 1’s are greater than 0’s defined over an alphabet set {0,1}.                                                        Marks [7]



Q2. Make a CFG corresponding to the following RE:               

 ab*(a+b)* b + ba*(a+b)*a                                                                  Marks [7]



Q3. Sà aSb | bSa | SS | ^                                                         

Show that the given grammar is ambiguous by running “abab” and creating any of its two different parse trees.                                                                               Marks [6]