Example 6
Ambiguous Grammar for Expressions
Consider the following version of the Expression grammar:
E --> E + E
E --> E * E
E --> (E)
E --> a
and input
a + a + a.
We can find the following left-most derivations: