decimate method

Iterable<T> decimate(
  1. int n
)

keep n equaly spaced elements of an array

Implementation

Iterable<T> decimate(int n) => takeEveryNth(math.max(1, length ~/ n));