-
Notifications
You must be signed in to change notification settings - Fork 5
every
Subhajit Sahu edited this page May 3, 2023
·
18 revisions
Examine if all values satisfy a test.
function every(x, ft)
// x: an array
// ft: test function (v, i, x)
const xarray = require('extra-array');
var x = [1, 2, -3, -4];
xarray.every(x, v => v > 0);
// → false
xarray.every(x, v => v > -10);
// → true