Array Methods

This List class re-creates simplified version of standard array functionality.

Map

Returns an array where each item has been transformed according to the callback function. Skips (but preserves) 'holes' in the array.

Filter

Returns an array containing only the elements that meet the criteria in the callback.

Find Index

Returns the index of the first element that meets the criteria in the callback, or -1 if no such element is found.

Reduce

Returns a single reduced value based on the callback (with or without initial value)

Every

Return false when any element does not meet the criteria in callback. Otherwise (all elements meet the criteria), returns true.