Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
import System.IO
main = do
todoItem <- getLine
appendFile "todo.txt" (todoItem ++ "\n")
@mizukmb
Copy link
Author

mizukmb commented Nov 25, 2017

すごいHaskellたのしく学ぼう! 『第9章 もっと入力、もっと出力』より

@mizukmb
Copy link
Author

mizukmb commented Nov 25, 2017

$ cat todo.txt
Iron the dishes
Dust the dog
$ ./appendtodo
Append TODO !!
$ cat todo.txt
Iron the dishes
Dust the dog
Append TODO !!

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