News for hackers. Stuff that matters.
Re:The Soft Side of Software by danidiaz on Friday May 12, 2017 @04:25PM (#14327589)
Cont is one of the trickier monads to "get".

Cont r a is a computation that knows how to produce an "a" but, instead of returning it directly, passes it to a function that takes the "a" and produces an "r".

Compared to typical sequential execution, this gives more power to the "current" phase of the computation, because it might choose to invoke the passed a -> r function more than one time, none at all, inspect the resulting "r" and change course based on the result, etc.

There are no comments on this comment yet.