this post was submitted on 09 Apr 2025
9 points (100.0% liked)
Haskell
547 readers
1 users here now
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
"Since we are talking about aggregating documents into an index, the word semigroup might pop into our heads."
This is why Haskell tutorials have a bad rep. Why not use a common English term like "monoid" instead?
Snark aside, the
<>
approach to solving the problem piecewise and aggregating the results into a larger instance of the same type is a really convenient approach.Not only is it convenient, it also enables parallelism:
"How to Think about Parallel Programming: Not!" - Guy L. Steele Jr. (Strange Loop 2010)
Yes! Steele's Fortress-era talks are amazing. Really thought-provoking.
Yes! Steele's Fortress-era talks are amazing. Really thought-provoking.