Skip to content

fx-flow v0.7.0 / pipe/strict / max

Function: max()

max<A>(iterator): IterableReturnValue<A>

Return the largest item of the iterable/asyncIterable

Type parameters

A extends Iterable<number> | AsyncIterable<number>

Parameters

iterator: A

Returns

IterableReturnValue<A>

Example

typescript
console.log(max([1, 2, 3])) // 3

More examples

Source

packages/core/src/pipe/strict/max.ts:40

Released under the MIT License.