JSFiddle - React, Tailwind, and code Playground

by Marco Iamonte

JavaScript

function union(...arrays) {
	return Array.from(new Set([...arrays].flat()));
}

console.log(union([5, 10, 15], [15, 88, 1, 5, 7], [100, 15, 10, 1, 5]));