Skip to content

Instantly share code, notes, and snippets.

@motokiee
Created October 1, 2015 10:34
Show Gist options
  • Save motokiee/277b210d3fda6eccc1c0 to your computer and use it in GitHub Desktop.
Save motokiee/277b210d3fda6eccc1c0 to your computer and use it in GitHub Desktop.
initials :: [(String, String)] -> [String]
initials xs = [pickup first last | (first, last) <- xs]
where pickup first last = [head first] ++ ". " ++ [head last] ++ "."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment