Portability | Portable |
---|---|
Stability | Experimental |
Maintainer | Dan Doel |
A simple insertion sort. Though it's O(n^2), its iterative nature can be beneficial for small arrays. It is used to sort small segments of an array by some of the more heavy-duty, recursive algorithms.
Documentation
sort :: (UA e, Ord e) => MUArr e s -> ST s ()Source
Sorts an entire array using the default comparison for the type
sortBy :: UA e => Comparison e -> MUArr e s -> ST s ()Source
Sorts an entire array using a given comparison