Skip to main contentSkip to solution

What will be the postfix equivalent of the expression (A + B)* (C - D)?

Solution

✅ Correct Option: 1

Postfix puts each operator after its two operands, and brackets are resolved first.

(A+B)(A + B) becomes AB+AB+, and (C−D)(C - D) becomes CD−CD-.

The final ∗* then goes after both: AB+ CD− ∗AB+\,CD-\,*


Option 4: ABC∗+D−ABC*+D- is the postfix of A+B∗C−DA + B * C - D, which ignores the brackets.

Options 2 and 3: the operators are swapped, so they give (A∗B)−(C+D)(A*B)-(C+D) and (A−B)+(C∗D)(A-B)+(C*D).

Keyboard Shortcuts

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