That is an unnecessary use of unsafeInterleaveIO. The solution is actually quite simple: getLines n = replicateM n getLine -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.haskell.org/pipermail/beginners/attachments/20160311/0bd4be3a/attachment.html>