Last active
August 29, 2015 14:26
-
-
Save guilleiguaran/4045a5994ff661364bba to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@annotate inc(Int) :: Int | |
def inc(num), do: num + 1 | |
@annotate id(A) :: A | |
def id(x), do: x | |
@annotate map([A], (A -> B)) :: [B] | |
def map(x, f), do: Enum.map(x, f) | |
@annotate abs(Number) :: Number | |
def abs(number), do: :erlang.abs(number) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
"Haskell-y" alternative