I have a context-free grammar defined: S -> aS, S -> Sb, S -> a
I thouht that correct answer would be: L(G) = {aab}, because: S -> aS -:> aSb -> aab but isn't. Why, and what is correct answer?
I have a context-free grammar defined: S -> aS, S -> Sb, S -> a
I thouht that correct answer would be: L(G) = {aab}, because: S -> aS -:> aSb -> aab but isn't. Why, and what is correct answer?
\tofor them. Also, is something like $a^5b^9$ in the language? Try to get closer to the right answer. (A proof would be induction, rather than inspection...) – dan_fulea Jun 16 '21 at 07:55