I have recently tried to find a good source on the difference between monads and monoids.
Could someone provide a link to a good resource on this or perhaps take one's time to elaborate on the similarities/differences?
I have recently tried to find a good source on the difference between monads and monoids.
Could someone provide a link to a good resource on this or perhaps take one's time to elaborate on the similarities/differences?
Monads are monoids in the category of endofunctors. Therefore, a monad is just one example of monoid, which is a more general concept.
And, though that might be technically true, the most simple answer is that monads and monoids are really nothing like each other, and you shouldn't be trying to learn the difference between them, but just learn them. There's ton of material about it on the internet, easily googled.
See this answer on why monads are special cases of monoids in monoidal categories. The latter is, however, a generalization of the classical monoid defined via binary operation and unit. Monad is not a classical monoid. See the answer for more details and explanations.
© 2022 - 2024 — McMap. All rights reserved.