Skip to content

Latest commit

 

History

History
32 lines (21 loc) · 598 Bytes

README.md

File metadata and controls

32 lines (21 loc) · 598 Bytes

ConsoleCalculator - The Reverse Polish Notation Calculator

I think it's the best version that I've seen (and created) - really.

An RPN console calculator that takes into account parntheses.

The symbols it works with are:

  • '+'
  • '-'
  • '*'
  • '/'
  • '('
  • ')'
  • ' ' (space)
  • '0' - '9'
  • ',' (seen as '.')
  • '.'

catch.hpp - libraty for unit-testing

calculator.cpp - main program

calculator.hpp - main header file to include

calculator_test.cpp - main program for unit-testing

To compile with g++:

g++ -std=c++11 -o calc calculator.cpp

g++ -std=c++11 -o calc_test calculator_test.cpp