Grabs elements from a largely unsorted array in linear time