haskell - Combining the state monad with the costate comonad -
how combine state monad s -> (a, s) costate comonad (e->a, e)?
i tried both obvious combinations s -> ((e->a, e), s) , (e->s->(a, s), e) in either case not know how define operations (return, extract, ... , on) combination.
haskell functional-programming monads category-theory comonad
No comments:
Post a Comment