- least<T>(iterable, comparator?): T | undefined
Parameters
iterable: Iterable<T>
Optional
comparator: ((a, b) => number)
- (a, b): number
Returns number
Returns T | undefined
- least<T>(iterable, accessor): T | undefined
Parameters
iterable: Iterable<T>
accessor: ((a) => unknown)
- (a): unknown
Returns unknown
Returns T | undefined
Returns the least element of the specified iterable according to the specified comparator. If comparator is not specified, it defaults to ascending.