misc Latest (v1.1.4)

zip

Accepts one or more arrays as arguments and returns an array of arrays

zip(arg: array[any]) -> array[array[any]]

Description

Accepts one or more arrays as arguments and returns an array of arrays in which the i-th array contains the i-th element from each of the argument arrays. The returned array is truncated to the length of the shortest argument array.

Arguments

Required

Name Type Description
arg array[any]

Returns

Type: array[array[any]]

Examples

search(zip([a, b], [1, 2]), null) → [["a",1],["b",2]]
search(zip([a, b, c], [1, 2]), null) → [["a",1],["b",2]]