Dear Cafe, It seems to me there should be some simple way of doing this, but thus far it eludes me. I am trying to combine the State and List monads to do the following:
countCalls = do a <- [1..2] b <- [1..2] modify (+1) return (a,b) where with some combination of ListT, StateT, List, State, or who knows what would result in: ([(1,1),(1,2),(2,1),(2,2)],4) assuming we initialize the state to 0 Is there any way to make this happen? Thanks in advance. Henry Laxen _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe