The following project is a small exploration of the Egyptian multiplication algorithm. The code was inspired by the From Mathematics to Generic Programming.
A non-recursive version using foldl was originally authored by Rodrigo Girão
Serrão after conversations on his blog Egyptian multiplication with
Haskell.
Haddock API documentation is available on:
To ensure package dependencies are installed, call:
make setupTo build run GNU Make with:
makeThis runs the default targets of check and fast.
make testThe first time you run the benchmarks, ensure doc target is called:
make doc benchAfter which you can run just:
make benchTo run the default multiplication algorithm (multiply4):
stack exec multiply 12 15