Iterable<T> sorted([int Function(T, T)? compare]) { final copy = toList(); copy.sort(compare); return copy; }