splitAt method

(Iterable<T>, Iterable<T>) splitAt(
  1. int n
)

Return a record where first element is an Iterable with the first n elements of this Iterable, and the second element contains the rest of the Iterable.

Implementation

(Iterable<T>, Iterable<T>) splitAt(int n) => (take(n), skip(n));