Error and state handling with monad transformers in Scala

In this post I will look at a practical example where the combined application (through monad transformers) of the state monad and the either monad can be very useful.

I won’t go into much theory, but instead demonstrate the problem and then slowly build it up to resolve it.

You don’t have to be completely familiar with all the concepts as the examples will be easy to follow. Here is a very brief overview:

Continue reading →