Skip to content

Latest commit

 

History

History
31 lines (19 loc) · 480 Bytes

union.md

File metadata and controls

31 lines (19 loc) · 480 Bytes

arrays.union

union(arrays)

Union creates an array of unique elements from all given arrays in order encountered

Arguments

  1. arrays (Array): input arrays

Returns

(Array): an array of unique elements from all given arrays

Example

const result = arrays.union([2], [1, 2, 3, 1]);
> [2, 1, 3]