4 ms·
I think one benefit is facilitating "getting to grips" with new code, much like design patterns in a way. Of course, this requires familiarity. If someone tells
by danidiaz 10y ago
I think one benefit is facilitating "getting to grips" with new code, much like design patterns in a way. Of course, this requires familiarity. If someone tells you something is a "monoid", you instantly know that the somethings can be combined in an associative way, and that there is a "neutral" something that can always be constructed without arguments.
Another benefit is that these abstractions appear again and again under many contexts. Recognizing them allows you to give them a common interface, instead of flatMap for lists, andThen for promises, and so on.