Builds and returns an array collected from the repeated calling of the given function.
number of items to collect
function to call repeatedly in order to construct each element of the array. It will be passed a counter (zero-based) indicating the number of the current iteration.
array of constructed items
Builds and returns an array collected from the repeated calling of the given function.