First of all, if you didn’t read the previous posts, go do so, otherwise you might be missing some essential concepts! _This is a translation of Functors, Applicatives, And Monads In Pictures from Haskell into Kotlin._hackernoon.com Kotlin Functors, Applicatives, And Monads in Pictures. Part 1/3 _This is a translation of Functors, Applicatives, And Monads In Pictures from Haskell into Kotlin._hackernoon.com Kotlin Functors, Applicatives, And Monads in Pictures. Part 2/3 Monads How to learn about Monads: Get a PhD in computer science. Throw it away because you don’t need it for this section! Monads add a new twist. apply a function to a wrapped value: Functors Applicatives apply a wrapped function to a wrapped value: Monads apply a function that returns a wrapped value to a wrapped value. Monads have a function ( or in Haskell) to do this. flatMap liftM >>= inline fun <B> flatMap(f: (A) -> Option<B>): Option<B> =when (this) {is None -> thisis Some -> f(value)} Let’s see an example. Good ol’ Option is a monad: Just a monad hanging out. Suppose is a function that only works on even numbers: half fun half(a: Int) = when {a % 2 == 0 -> Some(a / 2)else -> None} What if we feed it a wrapped value? We need to use ( in Haskell) to shove our wrapped value into the function. Here’s a photo of : flatMap >>= flatMap Here’s how it works: Some(3).flatMap(::half)// NoneSome(4).flatMap(::half)// Some(2)None.flatMap(::half)// None What’s happening inside? Let’s look at 's ( in Haskell) signature again: flatMap >>= // For Option So is a Monad. Here it is in action with a ! Option Some(3) And if you pass in a it’s even simpler: None You can also chain these calls (by using an infix version of ): flatMap Some(20) flatMap ::half flatMap ::half flatMap ::half// => None Note: the original article now describes Haskell’s _IO_ Monad. Kotlin doesn't have anything like that so this translation skips it. Conclusion A functor is a type that implements . map An applicative is a type that implements . apply A monad is a type that implements . flatMap implements and , plus we can extend it to implement , so it is a functor, an applicative, and a monad. Option map flatMap apply What is the difference between the three? : you apply a function to a wrapped value using . functors map : you apply a wrapped function to a wrapped value using . applicatives apply : you apply a function that returns a wrapped value, to a wrapped value using . monads flatMap So, dear friend (I think we are friends by this point), I think we both agree that monads are easy and a SMART IDEA(tm). Now that you’ve wet your whistle on this guide, why not pull a Mel Gibson and grab the whole bottle. Check out LYAH’s . There’s a lot of things I’ve glossed over because Miran does a great job going in-depth with this stuff. section on Monads Thanks for reading through this article series, if you have any feedback, suggestion, or error to report please tweet me @aballano , or leave a comment below. If you want to play around with the code head over to GitHub and clone the Playground Once again, thanks Adit for the wonderful post, and for all the other great ones on the blog . Happy Koding!