-
Notifications
You must be signed in to change notification settings - Fork 5
rejectAt
Subhajit Sahu edited this page Nov 20, 2022
·
13 revisions
Discard values at given indices.
Alternatives: reject, reject$, rejectAt.
Similar: map, filter, reject, reduce, accumulate.
function rejectAt(x, is)
// x: an array
// is: indices
const array = require('extra-array');
var x = [2, 4, 6, 8];
array.rejectAt(x, [1, 2]);
// → [ 2, 8 ]
array.rejectAt(x, [1, 3]);
// → [ 2, 6 ]