by runT1ME · 10y ago · 0 comments
You use the reader monad the thread the same input to multiple functions that may also take additional intput, and also have their own outputs.
You have to keep in mind that since Monads are so common and useful, many languages have syntactic support for them. C#'s LINQ query syntax, scala for expressions and haskell 'do' are all 'monadic comprehension'.
The resulting class can also have other variables and inputs.
Is that a correct analogy ?
Inheritance is more similar to monad transformers.