This is an associative, but not commutative monoid
Also, you must start on the right, with a value, and all subsequent RightFolded must
be RightFoldedToFold objects or zero
If you add two Folded values together, you always get the one on the left,
so this forms a kind of reset of the fold.
This is an associative, but not commutative monoid Also, you must start on the right, with a value, and all subsequent RightFolded must be RightFoldedToFold objects or zero
If you add two Folded values together, you always get the one on the left, so this forms a kind of reset of the fold.