Maintainer | bastiaan.heeren@ou.nl |
---|---|
Stability | provisional |
Portability | portable (depends on ghc) |
Safe Haskell | Safe-Inferred |
Language | Haskell98 |
A collection of general utility functions
- data Some f = forall a . Some (f a)
- data ShowString = ShowString {}
- readInt :: String -> Maybe Int
- readM :: (Monad m, Read a) => String -> m a
- subsets :: [a] -> [[a]]
- isSubsetOf :: Eq a => [a] -> [a] -> Bool
- cartesian :: [a] -> [b] -> [(a, b)]
- distinct :: Eq a => [a] -> Bool
- allsame :: Eq a => [a] -> Bool
- fixpoint :: Eq a => (a -> a) -> a -> a
- splitAtElem :: Eq a => a -> [a] -> Maybe ([a], [a])
- splitsWithElem :: Eq a => a -> [a] -> [[a]]
- useFixedStdGen :: IO ()
- timedSeconds :: Int -> IO a -> IO a
- fst3 :: (a, b, c) -> a
- snd3 :: (a, b, c) -> b
- thd3 :: (a, b, c) -> c
- headM :: Monad m => [a] -> m a
- findIndexM :: Monad m => (a -> Bool) -> [a] -> m Int
- elementAt :: Monad m => Int -> [a] -> m a
- changeAt :: Monad m => Int -> (a -> a) -> [a] -> m [a]
- replaceAt :: Monad m => Int -> a -> [a] -> m [a]
- list :: b -> ([a] -> b) -> [a] -> b
Documentation
data ShowString Source
isSubsetOf :: Eq a => [a] -> [a] -> Bool Source
splitAtElem :: Eq a => a -> [a] -> Maybe ([a], [a]) Source
splitsWithElem :: Eq a => a -> [a] -> [[a]] Source
useFixedStdGen :: IO () Source
Use a fixed standard "random" number generator. This generator is accessible by calling System.Random.getStdGen
timedSeconds :: Int -> IO a -> IO a Source
findIndexM :: Monad m => (a -> Bool) -> [a] -> m Int Source