edited by
345 views

2 Answers

Best answer
0 votes
0 votes
The language generated by the grammar is : $w(a+b+\varepsilon)w^{r}, |w|>=0, w\,\epsilon\,(a,b)$

For $0\,and\,1$ length string : $|w|=0$, strings = $a,b,\varepsilon$

For $2$ length strings, the strings are : $w(\varepsilon)w^{r}, |w|=1$

For $3$ length strings, the strings are : $w(a+b)w^{r}, |w|=1$

For $4$ length strings, the strings are : $w(\varepsilon)w^{r}, |w|=2$

For $5$ length strings, the strings are : $w(a+b)w^{r}, |w|=2$

For $6$ length strings, the strings are : $w(a+b)w^{r}, |w|=3$

Total = $3+2^{1}+2^{1}*2+2^{2}+2^{2}*2+2^{3}=29$
selected by

Related questions

0 votes
0 votes
1 answer
1
0 votes
0 votes
1 answer
2
suneetha asked Dec 22, 2018
549 views
G1: S-→ aSa| bSb|eG2:S → aaS|bbS| ethe shortest length strings which does not belongs to L(g1) but belongs to L(G2) is
1 votes
1 votes
0 answers
3
0 votes
0 votes
1 answer
4
ARUN KUMAR 3 asked Oct 12, 2016
548 views
If a parse tree is made for a w ε L(G), when G is in Chomsky-Normal form then what would be it's least height?? Plz explain what and how...