GATE Computer ScienceEasyGATE CS (PYQ pattern)

Evaluate the prefix expression - * + 4 5 - 9 3 / 20 + 2 3 (integer division truncating toward zero).

  1. A. 54
  2. B. 46
  3. C. 50
  4. D. 41

Correct answer: C. 50

(4 + 5) * (9 - 3) = 54 and 20 / (2 + 3) = 4, so 54 - 4 = 50.

More Programming and Data Structures (GATE) questions

Exams that ask this topic