Skip to content

symmetricDifference

symmetricDifference<T>(a, b, comparisonStrategy?): Iterable<T>

Defined in: set/symmetric-difference.ts:14

Computes the elements present in exactly one of a or b.

Time complexity: O(|a| + |b|) under the default "sameValueZero".

T

Iterable<T>

The first iterable.

Iterable<T>

The second iterable.

EqualityComparisonStrategy<T, T> = "sameValueZero"

The equality comparison strategy to use.

Iterable<T>

A Set of the elements in a or b but not both.