Using stack and arithmetic tree
Using stack and arithmetic tree
Hi everyone. I am now coding a calculator app but it work only for two numbers.. I mean a+b or a*b. I wondering modify this app it would be possible to calculate on many numbers and create order of operations and maybe it would be good to use stack to contain numbers and then use arithemtic tree?
Re: Using stack and arithmetic tree
Yes you can use tree to create calculator. There are tons of article about creating and evaluating expression tree.
Or you can use some library and not to do all work by yourself.
Or you can use some library and not to do all work by yourself.