operator << method

Iterable<E> operator <<(
  1. int count
)

Returns an Iterable that has been removed by the number of count from the beginning.

If count is negative it throws ArgumentError.

It is not in the Kotlin collection library. But I added it because it looks useful.

Implementation

Iterable<E> operator <<(int count) => count.isNegative
    ? throw ArgumentError.value(count, 'count', 'Cannot be negative')
    : skip(count);