Merge optimisticInsertionSort into a single function; Revise documentation for sort.