This is a simple CLI calculator made as an exercise in writing a simple lexer and parser.
It currently only handles simple arithmetic (addition, multiplication, subtraction, division).
Requirements:
-
opam>= 1.2 -
ocaml>= 4.05.0
The following libraries:
alcotest
Instructions:
make builds project
make calc builds and runs calculator
make test runs tests
To do:
-
unit test individual parsing stages
-
add more tests with randomised input