import { drop } from "https://deno.land/x/iter@v3.2.3/lib/transformers.ts";
Returns a new iterable containing the items of it
except the first n
items.
Examples
Example 1
Example 1
import * as iter from "https://deno.land/x/iter/mod.ts";
const numbers = iter.create.range(1, 10);
const from7 = iter.drop(numbers, 6);
for (const num of from7) {
console.log(num);
}
// -> 7
// -> 8
// -> 9
// -> 10
Parameters
it: Iterable<T>
- The iterable being taken from.
Returns
A new iterable of it
which skips the first n
items.