leetcode/lintcode/271-prefix-notation-to-postfix-notation
2022-04-13 04:55:09 +05:30
..
python3 add postfix solns 2022-04-13 04:55:09 +05:30
README.md add postfix solns 2022-04-13 04:55:09 +05:30

Given a string array representing an expression, and return the Reverse Polish notation of this expression. (remove the parentheses)

Definition of Reverse Polish Notation:

Example

Example 1:

    Input: ["3", "-", "4", "+", "5"] Output: ["3", "4", "-", "5", "+"] Explanation: 3 - 4 + 5 = -1 + 5 = 4 3 4 - 5 + = -1 5 + = 4

Example 2:

    Input: ["(", "5", "-", "6", ")", "*", "7"] Output: ["5","6","-","7","*"] Explanation: (5 - 6) * 7 = -1 * 7 = -7 5 6 - 7 * = -1 7 * = -7