Skip to content

Instantly share code, notes, and snippets.

@shigemk2
Created June 24, 2015 11:39
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 shigemk2/2fcb11020669ca841a7f to your computer and use it in GitHub Desktop.
Save shigemk2/2fcb11020669ca841a7f to your computer and use it in GitHub Desktop.
main = do line <- fmap reverse getLine
putStrLn $ "You said " ++ line ++ " backwards!"
putStrLn $ "Yes, you really said " ++ line ++ " backwards!"
main = do line <- getLine
let line' = reverse line
putStrLn $ "You said " ++ line' ++ " backwards!"
putStrLn $ "Yes, you said " ++ line' ++ " backwards!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment