replicateM package:rio

replicateM is the Seq counterpart of Control.Monad.replicateM.
replicateM n x = sequence (replicate n x)
For base >= 4.8.0 and containers >= 0.5.11, replicateM is a synonym for replicateA.
Like replicateM, but discards the result.

Examples

>>> replicateM_ 3 (putStrLn "a")
a
a
a