
But I have a vague recollection of an alternative syntax, something like
[(i,j) \ i <- [..], j <- [1..]]
that generated a list something like [(1,1),(1,2),(2,1),(1,3),(2,2),(3,1),...]. Did I dream this, or was it a feature of Miranda*, Gopher or Hugs many years ago?
Peter
A long time ago I came up with another kind of "monad" which did something like this. http://www.haskell.org/pipermail/haskell/2002-April/009327.html not that it was very useful. the distributions of the products were exponentially askew. (half of the results would be the result of combining one list with the firsts of every other lists, a quarter of the results would be the result of combining a second list with the first list and the firsts of every other list, an eighth would be...) and of course it would eat up stack for every item of the resulting list consumed. I kinda doubt this was the source of your dreams, but then again... Jay Cox