Skip to content

Instantly share code, notes, and snippets.

@bertrand-caron
Created June 27, 2016 03:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bertrand-caron/15723fbcb1632836877ba38fd8431144 to your computer and use it in GitHub Desktop.
Save bertrand-caron/15723fbcb1632836877ba38fd8431144 to your computer and use it in GitHub Desktop.
add :: Int -> Int -> Int
add x y = x + y
fs :: [(Int -> Int)]
fs = map (\n -> add n) [1..3]
main = do
print $ map (\f -> f 0) fs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment