Search for question
Question

2. Show a (i) parse tree, (ii) left most derivation and (ii) right most derivation for the following ambiguous Grammar: Here, S can be called as a Start variable which is related to A, B, where A and B are other variables which yield terminal symbols like a, b

• Construct an ambiguous string for the problem.

S→ aB | bA

S→ aS | bAA |a

B→ bS | aBB | b