我是Haskell的新手,我遇到了编译错误的问题。我不断收到以下错误:src \ Main.hs:26:22不在范围内:'threadDelay'运行以下代码时。我认为它必须与间距或标签有关,因为Haskell对此非常挑剔,但我似乎找不到我的问题所在。
eachMinute :: Bool -> Int -> [a] -> [a] -> String
eachMinute keepGoing num resevoir bin1
| keepGoing == False = ""
| otherwise = do answer resevoir bin1
threadDelay (1000 * 1000)
eachMinute keepGoing 0 resevoir bin1