keep n equaly spaced elements of an array
Iterable<T> decimate(int n) => takeEveryNth(math.max(1, length ~/ n));