Reverse Polish Notation is an easy way to process order of operations for a calculator on a computer. If you're unfamiliar with it or need a refresher head over to the wikipedia link above.
Today's problem will involve you building your own RPN outputer. You only need to handle the following operations: +-*/(). Here are some sample inputs and outputs.
IN: (3 - 4) x 5 OUT: 3 4 - 5 x IN: 5 + ((1 + 2) × 4) - 3 OUT: 5 1 2 + 4 × + 3 -
For a bonus output the answer to the equation.