diff --git a/curriculum/challenges/english/08-coding-interview-prep/algorithms/find-the-symmetric-difference.english.md b/curriculum/challenges/english/08-coding-interview-prep/algorithms/find-the-symmetric-difference.english.md index 8e1b03d681..136e764b6a 100644 --- a/curriculum/challenges/english/08-coding-interview-prep/algorithms/find-the-symmetric-difference.english.md +++ b/curriculum/challenges/english/08-coding-interview-prep/algorithms/find-the-symmetric-difference.english.md @@ -7,13 +7,14 @@ forumTopicId: 301611 ## Description
-Create a function that takes two or more arrays and returns an array of the symmetric difference ( or ) of the provided arrays. -Given two sets (for example set A = {1, 2, 3} and set B = {2, 3, 4}), the mathematical term "symmetric difference" of two sets is the set of elements which are in either of the two sets, but not in both (A △ B = C = {1, 4}). For every additional symmetric difference you take (say on a set D = {2, 3}), you should get the set with elements which are in either of the two the sets but not both (C △ D = {1, 4} △ {2, 3} = {1, 2, 3, 4}). The resulting array must contain only unique values (no duplicates). +The mathematical term symmetric difference ( or ) of two sets is the set of elements which are in either of the two sets but not in both. For example, for sets A = {1, 2, 3} and B = {2, 3, 4}, A △ B = {1, 4}. + +Symmetric difference is a binary operation, which means it operates on only two elements. So to evaluate an expression involving symmetric differences among three elements (A △ B △ C), you must complete one operation at a time. Thus, for sets A and B above, and C = {2, 3}, A △ B △ C = (A △ B) △ C = {1, 4} △ {2, 3} = {1, 2, 3, 4}.
## Instructions
- +Create a function that takes two or more arrays and returns an array of their symmetric difference. The returned array must contain only unique values (no duplicates).
## Tests