@extra-array/range-on.min
TypeScript icon, indicating that this package has built-in type declarations

2.7.8 • Public • Published

Finds smallest and largest values. 🏃 📼 📦 🌔

Alternatives: compare, map.
This is part of package extra-array.

This is browserified, minified version of @extra-array/range-on.
It is exported as global variable array_rangeOn.
CDN: unpkg, jsDelivr.

array.rangeOn(x, [fn], [ths]);
// x:   an array
// fn:  map function (v, i, x)
// ths: this argument
// --> [min, max]
const array = require('extra-array');

var x = [1, 2, -3, -4];
array.rangeOn(x);
// [-4, 2]

array.rangeOn(x, v => Math.abs(v));
// [1, -4]

references

Package Sidebar

Install

npm i @extra-array/range-on.min

Weekly Downloads

2

Version

2.7.8

License

MIT

Unpacked Size

7.96 kB

Total Files

19

Last publish

Collaborators

  • wolfram77