A friend of mine asked me why was I learning Haskell. To demonstrate the power of Haskell I wrote a small program which displayed a list of prime numbers:
ma
This looks more like a buffering than a sequencing problem. What platform are you on? Have you tried forcing unbuffered output?
hSetBuffering stdout NoBuffering -- from System.IO