cpp/algorithm/transform reduce

@1@ Equivalent to, effectively parallelized version of the default std. @2@ Applies to each pair of elements from the ranges  and the range starting at  and reduces the results (possibly permuted and aggregated in unspecified manner) along with the initial value  over. @3@ Applies to each element in the range  and reduces the results (possibly permuted and aggregated in unspecified manner) along with the initial value  over. @4-6@ Same as, but executed according to.

The behavior is non-deterministic if is not associative or not commutative.

The behavior is undefined if, or modifies any element or invalidates any iterator in the input ranges, including their end iterators.

Return value
@2@ Generalized sum of and, , ..., over. @3@ Generalized sum of and, , ... over ,

where generalized sum $GSUM(op, a 1, ..., a N)$ is defined as follows:
 * if $N = 1$, $a 1$
 * if $N > 1$, $op(GSUM(op, b 1, ..., b K), GSUM(op, b M, ..., b N))$ where
 * $b 1, ..., b N$ may be any permutation of $a1, ..., aN$ and

in other words, the results of transform or of reduce may be grouped and arranged in arbitrary order.

Complexity
@1,2,4,5@ $1 < K + 1 = M ≤ N$ applications each of and. @3,6@ $O(last1 - first1)$ applications each of and.