max
max() function
Returns the largest of the given iterable/AsyncIterable
Signature:declare function max<A extends Iterable<number> | AsyncIterable<number>>(iterable: A): ReturnValueType<A, number>;
Example
max([1, 3, 5]); // 5;
max([1, NaN, 2]); // NaN;
max([1, Infinity, 2]); // Infinity;
max([]); // -Infinity