Hi all
I am trying to understand how to use Types and specs and read the article on http://elixir-lang.org/getting-started/typespecs-and-behaviours.html but it is not clear.
For example a function with spec:
@spec add(number, number) :: {number, String.t}
def add(x, y), do: {x + y, "You need a calculator to do that?!"}
The parameter number is from type string?
Could someone explain me with some good sample?
Thanks