This is not exactly homework, but it is related to my research:
For example, the grammar is similar:
E → E + E | E * E | -E | (E) | id
After removing the ambiguity, it becomes (starting with the operator with the lowest priority)
E->-F|F
F->F+G|G
G->G*H|H
H->(E)|id
And after deleting the left recursion and left factoring (in this case is not required) the final grammar LL1:
E->-F|F
F->GF'
F'->+GF'|e
G->HG'
B->*HG'|e
H->(E)|id
Which gives a parser table without errors, which works fine. Now about the problem I am facing, suppose the grammar is this:
E → E + E | E * E | id = E | (E) | id
Now I can not create a parser table without conflicts, which means that my final grammar is not LL1. Here are the steps:
after removing the ambiguity:
E->id=F|F
F->F+G|G
G->G*H|H
H->(E)|id
, :
E->id=F|F
F->GF'
F'->+GF'|e
G->HG'
B->*HG'|e
H->(E)|id
Parser , , , - , , , . , , , . .