0 votes 0 votes Find a grammar that generates the language: L = {$w$$w^R$ : $w$ ∈ {a, b}+} Theory of Computation theory-of-computation grammar peter-linz peter-linz-edition4 context-free-language + – Garrett McClure asked Aug 31, 2017 • edited Mar 5, 2019 by Naveen Kumar 3 Garrett McClure 585 views answer comment Share Follow See all 0 reply Please log in or register to add a comment.
Best answer 2 votes 2 votes L = {wwR : w ∈ {a, b}+} Its the language representing the even length palindromes .L={aa,bb,abba.....} Following is the gammer which generates this:- S -> a S a | b S b | aa | bb rahul sharma 5 answered Aug 31, 2017 • selected Aug 31, 2017 by Garrett McClure rahul sharma 5 comment Share Follow See 1 comment See all 1 1 comment reply Garrett McClure commented Aug 31, 2017 reply Follow Share Could you explain a little bit about wwR? That's a string and its reverse, right? That's where aa and bb come from, because if you have aa, you also have to have bb? 0 votes 0 votes Please log in or register to add a comment.
0 votes 0 votes S->aSa /bSb /aa /bb /E suryaprakash answered Feb 8, 2018 suryaprakash comment Share Follow See all 0 reply Please log in or register to add a comment.