Tell us what’s happening:
I do not know how to express what is required. I understand that specific syntax should be used, but not where to obtain that from. Breaking down the sets isn’t all that difficult; i.e. finding the difference one set at a time. But, how am I to learn how to express this and know where to put it? Is there no guide for a beginner?
Your code so far
function sym(args) {
return args;
}
sym([1, 2, 3], [5, 2, 1, 4]); [3, 4, 5].
sym([1, 2, 3, 3], [5, 2, 1, 4]); [3, 4, 5]
sym([1, 2, 3], [5, 2, 1, 4, 5]); [3, 4, 5].
sym([1, 2, 5], [2, 3, 5], [3, 4, 5]) ; [1, 4, 5]
;
sym([3, 3, 3, 2, 5], [2, 1, 5, 7], [3, 4, 6, 6], [1, 2, 3]) ;[2, 3, 4, 6, 7]
sym([3, 3, 3, 2, 5], [2, 1, 5, 7], [3, 4, 6, 6], [1, 2, 3], [5, 3, 9, 8], [1]);[1, 2, 4, 5, 6, 7, 8, 9].
sym([3, 3, 3, 2, 5], [2, 1, 5, 7], [3, 4, 6, 6], [1, 2, 3], [5, 3, 9, 8], [1])
Your browser information:
User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.0 Safari/605.1.15
.
Challenge: Find the Symmetric Difference
Link to the challenge: