Essential Functional Structures: Functor, Applicative and Traverse
summary
Defines Functor, Applicative and Traverse in Scala with concrete code patterns and law checks, using Option, List, Either and Future to demonstrate map, ap, pure and compose. Shows using Applicative to combine multiple API calls and to perform validations with control over check ordering, and presents a traverse/sequence implementation that accumulates successes into a List but short‑circuits on the first error, plus guidance on replacing nested maps with composed contexts.
AI-written summary · about
chapters (17)
- 0:00Introduction
- 1:00REVISIONS - OPTION
- 1:51FUNCTOR: DEFINITION
- 4:29FUNCTOR: SPECS - MAYBE
- 5:02FUNCTOR: INSTANCE - MAYBE
- 5:48FUNCTOR: LAWS - IDENTITY
- 6:24FUNCTOR: LAWS - COMPOSITION
- 7:09FUNCTOR: COMPOSITION - INTRODUCTION
- 9:48APPLICATIVE - LIMITATIONS OF FUNCTOR
- 10:03APPLICATIVE - TWO METHODS: PURE
- 11:34APPLICATIVE - DEFINITION
- 13:03APPLICATIVE - INSTANCE: MAYBE
- 18:58TRAVERSE - LIMITATIONS OF APPLICATIVE
- 20:03TRAVERSE - INTRODUCTION
- 20:26TRAVERSE - SEQUENCE METHOD
- 21:46TRAVERSE - ANOTHER APPROACH
- 23:24TRAVERSE - TRAVERSE METHOD
related talks
45mA practical introduction to Category Theory
46mChasing Arrows, in categories containing functors and monads
33mApplying Functional Programming Patterns
29mTreasure.map(): Functional Programming in Kotlin
48mCategory Theory: You Already Know It
47mWhirlwind Tour of the Scala Functional Programming Ecosystem
43mEverything You Always Wanted to Know About Functional Programming...
01h 11mHands on Chat About Categories
