Skip to content

Instantly share code, notes, and snippets.



Last active Aug 29, 2015
What would you like to do?
main :: IO ()
main = do
str <- getLine
let [a,b] = words str
return ((read a :: Int) + (read b :: Int))

This comment has been minimized.

Copy link

@vlm 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