For grammar G E → E + n | E * n | n

For grammar G
E → E + n | E * n | n
For sentence W = n + n * n, the handle in the right sentential form of reduction are

(A) n, E + n, E + n * n
(B) n, E + n, E + E * n
(C) n, n + n, n + n * n
(D) n, E + n, E * n

Answer

(D) n, E + n, E * n

2Comments
Vimal Singh @vimal
16 Dec 2015 08:57 pm

We have to ourselves think of priority when not given ?

Parimal Andhalkar @parimal_andhalkar
5 Jan 2016 07:28 pm

if we give high priority to '*' then production required is n*E which is not present. 

∴ evaluate + first

Pages