Skip to content

Instantly share code, notes, and snippets.

@achempion
Last active August 29, 2015 14:06
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 achempion/e8e5a64b1cfd1567d667 to your computer and use it in GitHub Desktop.
Save achempion/e8e5a64b1cfd1567d667 to your computer and use it in GitHub Desktop.
main :: IO ()
main = do
str <- getLine
let [a,b] = words str
return ((read a :: Int) + (read b :: Int))
@vlm
Copy link

vlm commented Sep 19, 2014

main = do
  str <- getLine
  print $ sum $ map read $ words str

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment