Question: please specify the correct choice answer 5. Below are the LR(0) sets of items for the ambiguous grammar S'-> S S- S.S S-> S.S s-
please specify the correct choice answer

5. Below are the LR(0) sets of items for the ambiguous grammar S'-> S S- S.S S-> S.S s- [S] S-> SS S-> SS S-> SS to I S- (S) S- [S] S- [S] S-> S.S to 13 to I Since the grammar is ambiguous, we will have to resolve conflicts in some way. Build a simple-LR parsing table with the following heuristics to resolve conflicts 1. Prefer to shift rather than to reduce 2. Prefer to reduce by any production other than S if possible according to the SLR table-construction ules Construct this SLR parsing table. Then, identify from the list below the state-lookahead combination for which reduction by S is called for 0 O O O a) State 10 on lookahead S b) State I7 on lookahead S c) State I7 on lookahead ] d) State lo on lookahead)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
