main = myFunction myFunction = do c <- getChar if (c == 'q') then putStrLn "take action 1" else putStrLn "take action 2"