RPN (Reverse Polish Notation) is a postfix method of expression mathematical functions. It is traditionally used to eliminate the necessity of parenthesis by removing the order of operations and...


Please create a RPN Calculator with the following instructions


RPN (Reverse Polish Notation) is a postfix method of expression mathematical<br>functions.<br>It is traditionally used to eliminate the necessity of parenthesis by<br>removing the order of operations and acting on operators as they occur.<br>Very simply, INFIX notation

Extracted text: RPN (Reverse Polish Notation) is a postfix method of expression mathematical functions. It is traditionally used to eliminate the necessity of parenthesis by removing the order of operations and acting on operators as they occur. Very simply, INFIX notation "1 + 1" is represented in POSTFIX notation as: "1 1 +". Longer expressions may change radically. "1 + 2 * 3" assumes an order of operations, while in POSTFIX, "2 3 * 1 +" or "1 2 3 * +" The calculator works as follows: if number, push to a stack if operator, pop two numbers, operate on them, and push the result if I hit an operator and there are not two numbers on the stack, it's a bad expression if I get to the end of the expression and there is not exactly one number on the stack, it's a bad expression. FOR YOUR IMPLEMENTATION, 30 points: 10 for making something that looks like it works happening without a crash 10 for implementing LinkedListBasedStack 10 for implementing ArrayList the input to output YOUR CALCULATOR ONLY NEEDS TO WORK FOR +, -, and * YOUR CALCULATOR ONLY NEEDS TO WORK ON INTEGERS. 5 bonus points for working on Doubles (this is a gimme) 5 bonus points for implementing division / (this is deceptively hard, DO THIS LAST!)

Jun 06, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here