You spread Set into an array, so array won't have has method on it. Small bug on your side.
Oh you're right, first line should have been:
let firstValues = new Set(numOne);
Thanks for pointing that up
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.