Recent questions tagged grammar

3 votes
2 answers
241
1 votes
2 answers
242
0 votes
1 answer
243
0 votes
2 answers
244
0 votes
3 answers
245
0 votes
2 answers
246
0 votes
3 answers
247
L = (a^n b^n a^n | n = 1,2,3) is an example of a language that isA.context freeB.not context freeC. not context free but whose complement is CFD. both (b) and (c)
0 votes
3 answers
248
Let sigma = { a,b }.Find the grammar which generates the language,where na(w) and nb(w) denote the number of a's in w and number of b's in w respectively.
0 votes
1 answer
251
For the language L = { anbmcmdn : n , m>=1 }I came with following set of productions :S >aSd | AA bAc | bcwhereas the answer was given as belowS aSd | aAdA bAc | bcho...
0 votes
3 answers
252
Is the following language context-free?L= { uvwvR : u,v,w∈ {a,b}+ |u| = |w| =2 }If yes, provide set of productions for the same.
1 votes
2 answers
254
Give a context-free grammar for the language below :(n>=0, m>=0)L= { w ∊ {a,b}* : na(w)=2nb(w)+1}
2 votes
1 answer
255
Find the context-free grammar for the following language(n>=0 and m>=0) ?L={an bm : n<=m+3}
0 votes
1 answer
257
0 votes
1 answer
258
1 votes
2 answers
260
ARE NUMBER OF SHIFT ENTRIES / ACTIONS IN PARSING TABLE OF SLR(1) AND LALR(1) SAME ALWAYS??
1 votes
2 answers
263
Can set of terminal be empty in a grammar? Is epsilon (null string) counted as a terminal symbol?
3 votes
1 answer
264
Consider these three grammars.$$\begin{array}{|c|c|c|} \hline \textbf{Grammar G1:} & \textbf{Grammar G2:} & \textbf{Grammar G3:} \\ \hline E\rightarrow E+T \mid T & E\r...
5 votes
2 answers
268
How to do this type of QUESTIONS?Consider following grammar : S → S1 + A | A A → D – A | D D → D1 * B | B B → num The number of internal nodes for the parse tre...