I seem to think there are bugs and then find out they aren’t so I want to post this here before reporting it.
My code below works fine in repl.it and in the google chrome console, but when I submit it as the answer for Symmetrical difference, I get an error that says arrays[2].forEach() is not a function.
Have you tried console.logging your arrays.length?
It doesn’t behave the way you are expecting. In the example above: sym([1,2,3], [5,2,1,4])
…the length of (arrays) is 3, even thought the there are TWO arguments being passed. It is measuring the length of only the first argument, an array that is 3 long!!
If you check arguments.length though, you’ll get the behaviour you are expecting.
Thanks for the reply, but the function works. It works in repl, it works in the console, it just doesn’t work in freecodecamp. I wanted it to measure the length that way.