문제

S-> A|B|AB

A-> aA, B-> bB, A->€, B->€

€ is the empty string.

Find a string and show that it has two

a-) parse trees b-) leftmost derivations c-) rightmost derivations

도움이 되었습니까?

해결책

We're not gonna do your homework.

Build the parse tree using leftmost and rightmost derivations. If you can find any ambiguity, it is ambigious.

S-> A|B|AB is the key part. Try using both A, B and AB.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top