- zip-interval intervalprocedure
- reverse-zip-interval intervalprocedure
Transducers that zip the indices contained within the interval to another transduction, in forward or reverse order.
(import (generalized-arrays intervals) (transducers) (test)) (test "Zipping an interval onto elements of a list" (list (cons 'a (vector 0 0)) (cons 'b (vector 0 1)) (cons 'c (vector 1 0)) (cons 'd (vector 1 1))) (transduce list-fold (zip-interval (make-default-interval (vector 2 2))) (collect-list) (list 'a 'b 'c 'd 'e)))