t-eckert / react-rpn

A Reverse Polish Notation Calculator in ReactJS
2 stars 0 forks source link

Issues with subtraction? #3

Closed AustinTSchaffer closed 6 years ago

AustinTSchaffer commented 6 years ago

Maybe the readme needs to be more clear but, subtraction seems to be backwards.

Rather, what is (4 8 -) supposed to evaluate to? Should it be 4 or -4?

Not sure if this is just the way the UI works, versus how polish math notation works, but push 8, push 4, subtract, gives the answer positive 4.

AustinTSchaffer commented 6 years ago

Nevermind, I looked it up. The way you have it is correct.