From 17d5db9d9f3f3a344c4c2d66c62d6049f29ab51e Mon Sep 17 00:00:00 2001 From: Samir Benmendil Date: Sat, 13 Jan 2018 22:07:28 +0000 Subject: [PATCH] Reading input from stdin Introducing `getLine` which reads the next line from stdin. --- app/Main.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Main.hs b/app/Main.hs index 16e4939..a938cf0 100644 --- a/app/Main.hs +++ b/app/Main.hs @@ -3,5 +3,5 @@ import System.Environment main :: IO () main = do - args <- getArgs - putStrLn (show (read (args !! 0) + read (args !! 1))) + args <- getLine + putStrLn (args) -- 2.48.1