A sequence, whose i-th element contains the i-th element from each of the Packs.
alias Result1 = ZipWith!(AliasSeq, Pack!(1, 2), Pack!(5, 6), Pack!(9, 10)); static assert(Result1 == AliasSeq!(1, 5, 9, 2, 6, 10)); alias Result2 = ZipWith!(AliasSeq, Pack!(1, 2, 3), Pack!(4, 5)); static assert(Result2 == AliasSeq!(1, 4, 2, 5)); alias Result3 = ZipWith!(AliasSeq, Pack!(), Pack!(4, 5)); static assert(Result3.length == 0);
Zips one or more $(D_PSYMBOL Pack)s with f.
Given f and tuples t1, t2, ..., tk, where tki denotes the i-th element of the tuple k-th tuple, $(D_PSYMBOL ZipWith) produces a sequence:
$(D_PSYMBOL ZipWith) begins with the first elements from Packs and applies f to them, then it takes the second ones and does the same, and so on.
If not all argument tuples have the same length, $(D_PSYMBOL ZipWith) will zip only n elements from each tuple, where n is the length of the shortest tuple in the argument list. Remaining elements in the longer tuples are just ignored.