Ask Question
12 July, 03:30

What is infix, prefix and postfixexpressions in data structures?

+2
Answers (1)
  1. 12 July, 05:22
    0
    Infix notation: A+B

    Operators are written in-between their operands. Expression X * (Y + Z) / P is means: "First add Y and Z together, then multiply the result by X, then divide by P to give the final answer."

    Postfix notation : A B +

    Operands are written before their operators. Expression given above is equivalent to X Y Z + * P /

    Operators evaluation is always left-to-right, we will not consider brackets for the order.

    Prefix notation : + A B

    Operands are written after their operators. Expression given above is equivalent to / * X + Y Z P

    Operators evaluation is always right-to-left, we will not consider brackets for the order.
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “What is infix, prefix and postfixexpressions in data structures? ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers