+ 1
Can anyone help me fix this code in java or any other language (postfix expression evaluation)?
2 ответов
0
There have is not one mistake, but I'll tell you where to start:
The class "Evaluation" and the method of calculation have incorrectly placed "}".
I did not understand the logic, but I ask you to note that the method must return int.
Also, be careful with the implementation of Stack, it does not provide protection against ArrayIndexOutOfBoundsException.