What is the best way to make a PEMDAM Calculator

Hello

as my first project after watching the videos of McWorther I want to make a PEMDAM calculator.
So you can enter a calculation in the serial monitor and the end result is displayed on a LED screen.

So far no problem

But is it a good waty to use two stacks to take care that the calculations are done in the right order or is there a better way ?

Do yo mean pemdas?
Why the two stacks? You really need to explain your idea better...

yes. I mean that
I was thinking of 2 stacks. one for the numbers and one for the operations.

So lets say we want to solve this calculation : 2 + 3 * 8

Then I first store the 2 in the numbers stack
Then I see a + so I store it on the operations stack.
Then I see a 3 so I store it on the numbers stack
Then I see a * so I can "compare" if the * has a higher priority as the + which it has
Then I see the 8 so I can get a operation from the operations stack and a number and calculate 3 * 8 which is 24.
Then I can store the 24 in the numbers stack.
Then I can get 2 numbers from the numbers stack and a operation so I can calculate 2 + 24 = 26

Which is then the answer.
I hope this explanation is clear.

The best way is the way that works correctly, is easy to use and maintain, is fast, accurate and the code fits into the target processor.

Ok, that makes sense.
And is doable...

Most cheap calculators have an order. I don't call it right, but it is what it is. No stacks are involved.

If you want a useful calculator that does a better job, you might want to provide for parentheses.

a7

First, I'd work through serial parsing, and then I'd skip PEMDAS and just do RPN/postfix.

Use one stack to convert from infix to postfix. Then use the other stack to evaluate the postfix expression.

There is this old publication. ("My Dear Aunt Sally" Algorithm)
It was clear enough for me to implement it, ~45 years ago.

Thanks
Could be working but first study a lot to really understand things.
Will costs time but that is oke .