Skip to main contentSkip to solution

What will be the correct order in which operators will be evaluated in following postfix expression?

5 8 4 / 7 * + 2 -

(A). /

(B). *

(C). +

(D). -

Solution

✅ Correct Option: 1

Postfix is read left to right. An operator is applied to the two most recent operands as soon as it appears.

(A) // : 8/4=28 / 4 = 2, leaving 5 2 7…5\ 2\ 7 \ldots

(B) ∗* : 2∗7=142 * 7 = 14, leaving 5 14…5\ 14 \ldots

(C) ++ : 5+14=195 + 14 = 19, leaving 19 2…19\ 2 \ldots

(D) −- : 19−2=1719 - 2 = \boxed{17}

Keyboard Shortcuts

  • Left arrow: Previous question
  • Right arrow: Next question
  • S key: Jump to solution
  • Q key: Jump to question