mirror of
https://github.com/Jaxan/ons-hs.git
synced 2025-04-27 14:47:45 +02:00
Adds hFlush for IO
This commit is contained in:
parent
2ee2f091cb
commit
2b6a011551
1 changed files with 4 additions and 0 deletions
|
@ -15,6 +15,7 @@ import qualified EquivariantSet as Set
|
|||
|
||||
import Data.List (tails)
|
||||
import Control.Monad.State
|
||||
import System.IO (hFlush, stdout)
|
||||
import Prelude hiding (filter, null, elem, lookup, product, Word, map, take, init)
|
||||
|
||||
-- We use Lists, as they provide a bit more laziness
|
||||
|
@ -158,6 +159,7 @@ askMember w = do
|
|||
putStr "MQ \""
|
||||
putStr (toStr w)
|
||||
putStrLn "\""
|
||||
hFlush stdout
|
||||
a <- getLine
|
||||
case a of
|
||||
"Y" -> return True
|
||||
|
@ -169,6 +171,7 @@ askEquiv aut = do
|
|||
putStr "EQ \""
|
||||
putStr (toStr aut)
|
||||
putStrLn "\""
|
||||
hFlush stdout
|
||||
a <- getLine
|
||||
case a of
|
||||
"Y" -> return Nothing
|
||||
|
@ -186,6 +189,7 @@ init alph = Observations
|
|||
main :: IO ()
|
||||
main = do
|
||||
putStrLn "ALPHABET"
|
||||
hFlush stdout
|
||||
alph <- getLine
|
||||
case alph of
|
||||
"ATOMS" -> do
|
||||
|
|
Loading…
Add table
Reference in a new issue