Question: 1. Consider the grammar S -> 0S1 | SS | 10. Show a parse tree produced by this grammar for string 010110. 2. Build a
1. Consider the grammar S -> 0S1 | SS | 10. Show a parse tree produced by this grammar for string 010110.
2. Build a context-free grammar for the language:
(a) {w {a,b}*: every prefix of w has at least as many a's as b's}.
(b) {anbm:m n,m-n is even}.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
