[Haskell-cafe] Needing strictness?

michael rice nowgate at yahoo.com
Wed Oct 21 22:15:56 EDT 2009

Busy night. I wanted the question and response to be on the same line (see below), so I used putStr instead of putStrLn, but Haskell jumps the gun and goes to the second line to get the response before the question ever gets printed. Is this an example of needing strictness? How would I do that, or something else, to get the result I want? 

         putStrLn "Some yes/no question (y/n)?"
         ans <- getLine


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20091021/4362f3ba/attachment.html

More information about the Haskell-Cafe mailing list