(A) S ->asb|bsa|e
(B) S->asa|bsb|e
(C) S ->asb|bsa|asa|bsb|e
(D) S ->asb|bsa|asa|bsb
Answer(B).
S-> aSa
S->abSba
S->abaSaba
S->abaaSaaba.
S-> abaaaaba
Produces the
reverse string on every production applied.
No comments:
Post a Comment
Note: only a member of this blog may post a comment.