Re:Functors and Monads for People Who Have Read Too Many “Tu...
by 0xFF69B4 on Saturday June 26, 2021 @06:25AM
(#27640725)
Monads and Functors aren't particularly exciting in Python because properties or contexts can be expressed with e.g. boolean flags and properties or contexts can be ignored when applying functions to unrelated parts of an object.
In Haskell there would be a 'Tired a' type with a Monad instance to express the tiredness property and a Functor instance to apply functions to it with no impact on or knowledge of tiredness, e.g. aging.
[ Parent
| on HN ]
There are no comments on this comment yet.