Final answer:
The given grammar is proven to be ambiguous by demonstrating that the string 'acb' can be derived in two distinct ways, showing it has multiple parse trees.
Step-by-step explanation:
To prove a grammar is ambiguous, we must show that there exists at least one string which can be generated by the grammar in two different ways, meaning it has two distinct parse trees. For the given grammar with variables S, T, and U and productions S->aS | xS | Tb | aU, T->cT | U | c, and U->xUx | Ub | cU | null, we can find such a string.
Consider the string 'acb'. This string can be generated in two ways:
- Starting from S, then to Tb, and finally expanding T to cU followed by U to null.
- Starting from S, then to aU, next expanding U to cU, and finally expanding the second U to null followed by appending b.
Since the string 'acb' can be derived in two distinct ways, we can conclude the grammar is ambiguous.