sorter.c
static int partition(int* array, int start, int end)
{
    
    
    int pivot = start;
    int i;
    for(i = start; i<end;i++)
    {
        if(array[i]<= array[end])
        {
            swap(array,i,pivot);
            pivot++;
        }
    }
    swap(array,pivot,end);
    return pivot;
}
/*
 * Finds a  median of the first, middle and end elements
 * Moves the median element to the end of the array
 * Takes the elements of the array from start to end
 * Track a position to store the median.
 * Array elements get put to the left/right of this
 * At the end median is put into this tracked position
 */
Finds a  median of the first, middle and end elements
Moves the median element to the end of the array
Takes the elements of the array from start to end
Track a position to store the median.
Array elements get put to the left/right of this
At the end median is put into this tracked position
Finds a median of the first middle and end elements Moves the median element to the end of the array Takes the elements of the array from start to end Track a position to store the median . Array elements get put to the left / right of this At the end median is put into this tracked position
static int partition(int* array, int start, int end)
{
    int pivot = start;
    int i;
    for(i = start; i<end;i++)
    {
        if(array[i]<= array[end])
        {
            swap(array,i,pivot);
            pivot++;
        }
    }
    swap(array,pivot,end);
    return pivot;
}
static int partition ( int * array , int start , int end ) { int pivot = start ; int i ; for ( i = start ; i < end ; i ++ ) { if ( array [ i ] <= array [ end ] ) { swap ( array , i , pivot ) ; pivot ++ ; } } swap ( array , pivot , end ) ; return pivot ; }
Finds a  median of the first, middle and end elements
 Moves the median element to the end of the array
 Takes the elements of the array from start to end
 Track a position to store the median.
Finds a median of the first middle and end elements Moves the median element to the end of the array Takes the elements of the array from start to end Track a position to store the median .