Skip to content

isSupersetOf

isSupersetOf<T>(a, b, comparisonStrategy?): boolean

Defined in: set/is-superset-of.ts:15

Checks whether every element of b is also in a.

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

T

Iterable<T>

The candidate superset.

Iterable<T>

The candidate subset.

EqualityComparisonStrategy<T, T> = "sameValueZero"

The equality comparison strategy to use.

boolean

true if a is a superset of b (every element of b is in a).