Recent questions tagged compiler-design

0 votes
1 answer
1801
Which of the following set could result SR conflict in LALR(1)?a) A→ a.b, {b} B→ a. , {a}b) A→ a.a , {a} B→ a. , {b}c) A→ b.a , {b} B→ b.,{a}d) A→ b...
1 votes
2 answers
1802
Consider the following grammerS→ bAd /bBeA→aB→aThe above grammer is ________________1) SLR(1)2) LALR(1) but not SLR(1)3) CLR(1) but not LALR(1)d) Not LR(1)
1 votes
3 answers
1803
Which of the following could result in Shift-Reduce conflict in LR(0) parser?1){ A→ b.c ,B→b. }2){A→a.b,B→b. }3) {A→∊. , B→.a}4)All of these
0 votes
2 answers
1804
S'→SS→A/BA→fAi/nB→fBii/dFor the above augmented grammer , the number of states in LR(1) parser are_______________
0 votes
1 answer
1805
Ques:- Check whether the following grammar is clr(1) grammar or not or lalr grammar or not.S - (S)S - aProblem-The work( for checking the given grammar is LR(1) or not) d...
2 votes
2 answers
1807
check whether the following grammer is ll(1) grammar or not and also find the table entry of [A,a].S ->A,A->aB/Ab,B->bBC/d,C->dWhy is this not a LL(1) grammar?
5 votes
2 answers
1808
What is the difference in between lexical, syntax and semantic errors?Please give appropriate example also.
2 votes
1 answer
1809
During code generation, we need to do register allocation (kind of machine dependent stuff). So, I think it must be the part of Synthesis phase?
3 votes
1 answer
1810
give example for LL(*) grammar
0 votes
3 answers
1811
In this one I am unable to follow in the above node marked as "-" ,it has two edges one upward and one downward for "+" node so then how to proceed with this ?
2 votes
3 answers
1812
can int a=a 10 is a lexical or notif yes then why ???if no then give reason?
11 votes
2 answers
1816
Does there exist LL(1) grammar for every Regular Language ? ORFor Every Regular Language there exist atleast one LL(1) Grammar . True /False
2 votes
1 answer
1818
2 votes
2 answers
1819
First one not LL1 as it is ambigous,option c is left recursive,cant decide about option b.... plss help..
1 votes
1 answer
1826
Given answer: 1I am able to get 2 rightmost derivation of 'a+a'First:S - E + E - E + a - a + aSecond:S - E + E - E + a - a + aTotal derivation - 2
1 votes
3 answers
1827
0 votes
1 answer
1828
Given answer: CBut I believe that syntax analyzer is just for checking the form of the source code. The meaning of the program is interpreted in semantic analyzer phase o...
0 votes
1 answer
1829
0 votes
1 answer
1830
Given answer: DSolution to this problems says that the grammar is same as dangling else problem. Please explain me how.