reduce anything
Install with component(1):
$ component install yields/reduce
assert(3 == reduce({ a: 1, b: 2 }, sum, 0));
assert(3 == reduce([1, 2], sum, 0));
assert(198 == reduce('abc', sum, 0));
MIT
reduce anything
Install with component(1):
$ component install yields/reduce
assert(3 == reduce({ a: 1, b: 2 }, sum, 0));
assert(3 == reduce([1, 2], sum, 0));
assert(198 == reduce('abc', sum, 0));
MIT