by Thomas Nijssen
Version 1 (September 19, 2020)
Download (53 downloads)
Simple example of a calculator for math expressions. Give it an input like "5+(1-2)" and it will first convert it to Reverse Polish Notation (RPN) «5 1 2 - +» and then evaluate it using a stack. It respects order of operations (PEMDAS - no exponent in this version)
This version only handles addition, subtraction, multiplication, division, and parentheses. Negative numbers don't work yet.
You can use this as an example for how to parse user input.
5 stars | 2 | |
4 stars | 0 | |
3 stars | 0 | |
2 stars | 0 | |
1 star | 0 | |
Reports | 0 |
Rate and review within the app in the Community section.