Monad - FunFunFunction #21
Fun Fun Function3 HN recommenders · recommended in 3 months, 2016–2021
tutorial · intermediate · evergreen · 2016–2021 on HN
An episode of FunFunFunction explaining monads in JavaScript as functors that also implement flatMap. It builds on the preceding functor episode and works through code examples.
Recommended to people confused by monads as a friendly, practical explanation for JavaScript developers, with one commenter saying it finally made it click.
Up next
2 mo on HNLet's teach for mastery -- not test scores | Sal Khan
TED
2 HN recommender · 2016–2018
1 mo on HNDouglas Crockford: Monads and Gonads (YUIConf Evening Keynote)
YUI Library
1 HN recommend · 2013–2020
5 mo on HNReact.js Conf 2015 - Immutable Data and React
Meta Developers
5 HN recommender · 2015–2022
6 mo on HNEvan Czaplicki - Let's be mainstream! User focused design in Elm - Curry On
Curry On!
7 HN recommender · 2015–2023
2 mo on HNIs Nuclear Energy Green?
Sabine Hossenfelder
2 HN recommender · 2022–2022
18 mo on HNRuby Conf 12 - Y Not- Adventures in Functional Programming by Jim Weirich
Confreaks
17 HN recommender · 2013–2026
14 mo on HNThe Soul of Erlang and Elixir • Sasa Juric • GOTO 2019
GOTO Conferences
16 HN recommender · 2019–2024
14 mo on HN"Simple Made Easy" - Rich Hickey (2011)
Strange Loop Conference
14 HN recommender · 2022–2026
13 mo on HN"Making Impossible States Impossible" by Richard Feldman
elm-conf
9 HN recommender · 2017–2026
12 mo on HNWilliam Byrd on "The Most Beautiful Program Ever Written" [PWL NYC]
PapersWeLove
11 HN recommender · 2017–2026
11 mo on HNThe Value of Values with Rich Hickey
InfoQ
10 HN recommender · 2014–2023
12 mo on HNWhy Isn't Functional Programming the Norm? – Richard Feldman
Metosin
12 HN recommender · 2019–2025
4 comments from Hacker News
I read this example years ago, and it didn't clear anything up for me. After half a year of trying to understand monads, I saw a video by MPJ/Funfunfunction [0] and it finally made sense. [0] ▶ this video
Here's a half baked explanation, as in just the flatmap part. map is understood in javascript. So you 'just' need to make the leap to flatmap. Which is mapping something and flattening the result. So still you need to learn is what flatten is. But that's not too hard to learn. Try the funfunfunction video [0] [0]: ▶ this video
I like how mpj explains it. Monad - FunFunFunction #21 ▶ this video Furthermore, the creator of Elm has a fun explanation too. Evan Czaplicki - Let's be mainstream! User focused design in Elm - Curry On link More serious computer scientist explains monads in the following. Erik Meijer: Functional Programming link and here too link
A nomad is something that goes "nom!" ;) A monad is basically an function, in the algebra sense, that will take a set of input, and map it to a different output. That's the most simple definition I can give without getting into the math, and it's been a minute since I've really gotten into Group theory. Maybe through a Haskell tutorial for some hands-on guidance? link ▶ this video