Skip to content
Subhajit Sahu edited this page Feb 3, 2021 · 15 revisions

Removes first n values. 📦 😺 🏃 📼 🌔 📜 📰 📘

Alternatives: drop, drop$.
Similar: take, drop.


set.drop(x, [n]);
// x: a set
// n: number of values (1)
const set = require('extra-set');

var x = new Set([1, 2, 3, 4, 5]);
set.drop(x, 2);
// Set(3) { 3, 4, 5 }

set.drop(x, 3);
// Set(2) { 4, 5 }


References

Clone this wiki locally