Take the given amount of items from the iterable or asynchronous iterable.
const take2 = take(2);take2([1, 2, 3, 4, 5]); // [1, 2] Copy
const take2 = take(2);take2([1, 2, 3, 4, 5]); // [1, 2]
Amount of items to take.
Curried function with amount in context.
amount
Take the given amount of items from the iterable or asynchronous iterable.
Example