Open In App

ISRO | ISRO CS 2020 | Question 20

Given the grammar:

s → T * S⏐T
T → U + T⏐U
U → a⏐b 

Which of the following statement is wrong ?
(A) Grammar is not ambiguous
(B) Priority of + over * is ensured
(C) Right to left evaluation of * and + happens
(D) None of these

Answer: (D)
Explanation: Following points can be drawn from above grammar :

  1. * is right associative.
  2. + is right associative.
  3. Priority of + is higher than *.
  4. Grammar is not ambiguous since preferences are defined.

So, option (D) is true.
Quiz of this Question

Article Tags :