This calculator is designed based on
Shunting Yard Algorithm.
It is a method for parsing mathematical expressions specified in infix
notation. It can be used to produce either a post fix notation string, also
known as Reverse Polish notation (RPN), or an abstract syntax tree (AST). The
algorithm was invented by
Edsger Dijkstra and named the "Shunting
yard" algorithm because its operation resembles that of a railroad shunting
yard. Please read the attached PPT for the better understanding of the
algorithm.