loadList

open fun <T> loadList(length: Int, @NonNull loader: IntFunction<T>): List<T>

Creates list with items from 0 (inclusive) to length (exclusive) and fills it with values provided by loader.