GATEverse
← GATE CSE 1991

Q10a

NATMarks unknown

Consider the following grammar for arithmetic expressions using binary operators −- and // which are not associative E→E−T∣TE \rightarrow E -T\mid T T→T/F∣FT \rightarrow T/F\mid F F→(E)∣idF \rightarrow (E) \mid id (EE is the start symbol) Is the grammar unambiguous? Is so, what is the relative precedence between −- and //? If not, give an unambiguous grammar that gives // precedence over −-.

Sign in to save attempts.

Loading…