07-12-2010, 05:29 AM
Question No 1:
Find the prefixes of Q in R where Q and R are languages given below:
Q={ ababa , aabbbbbbb,baabba , babbaaaaaa }
R={ aababa , bbaabba , bbaababa, aaaabbbbbbb, abbabbaaaaaa}
Question No. 2
Describe the language (in English) generated by the following CFG:
S --> XY
X --> aX | bX | lambda
Y --> baa | bab | bba | bbb
Question No. 3
Construct the CFG that generates the language L = {w belong to {a, b}*: length(w) >= 2 and w begins with b and ends in aa or bb}.
Find the prefixes of Q in R where Q and R are languages given below:
Q={ ababa , aabbbbbbb,baabba , babbaaaaaa }
R={ aababa , bbaabba , bbaababa, aaaabbbbbbb, abbabbaaaaaa}
Question No. 2
Describe the language (in English) generated by the following CFG:
S --> XY
X --> aX | bX | lambda
Y --> baa | bab | bba | bbb
Question No. 3
Construct the CFG that generates the language L = {w belong to {a, b}*: length(w) >= 2 and w begins with b and ends in aa or bb}.
