Skip to content

difference

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

Defined in: set/difference.ts:14

Computes the elements in a that are not in b.

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

T

Iterable<T>

The iterable to subtract from.

Iterable<T>

The iterable of elements to exclude.

EqualityComparisonStrategy<T, T> = "sameValueZero"

The equality comparison strategy to use.

Iterable<T>

A Set of the elements present in a but not in b.