def exclusive
import bend-parallel@0.1.0.0/scan.bend as Scanimport Base
227# a[j] becomes a[0] + .. + a[j - 1] (a[0] becomes 0); returns the array
228# and the total, a[0] + .. + a[n - 1].
229def exclusive(+b: Nat, a: Array<U32>) -> Array<U32> & U32:
230 run(False{}, b, Array.size(U32, a))