/cpp-shunting-calc

Basic calculator implementation in C++ with the Shunting Yard algorithm.

Primary LanguageC++MIT LicenseMIT

Shunting-Yard Calculator

This project is a basic implementation of the Shunting-Yard algorithm which is used to parse an infix notation input and turn it into a list of tokens arranged with the Postfix notation. The postfix tokens would then be evaluated using a stack-based algorithm.

P.S this is for my school assignment.

Implemented Features

  • Precedence respect
  • Operators: +, -, /, *
  • Parenthesis support
  • Floating-point numbers support
  • Simple REPL

Building and Running

git clone https://github.com/DaringCuteSeal/cpp-shunting-calc calculator
cd calculator
make

Then run the calculator executable.

License

Licensed under the MIT license.