Exercise to play with typespecs, docs, guards and strings in elixir.
The problem it solves is to evaluate strings like "(2 * 8) / 4" without using somethink like eval.
If available in Hex, the package can be installed
by adding calc
to your list of dependencies in mix.exs
:
def deps do
[
{:calc, "~> 0.1.0"}
]
end
Documentation can be generated with ExDoc and published on HexDocs. Once published, the docs can be found at https://hexdocs.pm/calc.