docs: private static <T extends Comparable<? super T>> 
      void quicksort( T[] arr, int left, int right )
      {
          if ( left + CUTOFF <= right  ) {
              //find the pivot
              T pivot = median( arr, left, right );
              
              //start partitioning
              int i = left, j = right - 1;
              for ( ; ; ) {
                  while ( arr[++i].compareTo( pivot ) < 0 ) ;
                  while ( arr[--j].compareTo( pivot ) > 0 ) ;
                  if ( i < j ) {
                      swapReferences( arr, i, j );
                  } else {
                      break;
                  }
              }
              
              //swap the pivot reference back to the small collection.
              swapReferences( arr, i, right - 1 );
              
              quicksort( arr, left, i - 1 );        //sort the small collection.
              quicksort( arr, i + 1, right );        //sort the large collection.
              
          } else {
              //if the total number is less than CUTOFF we use insertion sort instead.
              insertionSort( arr, left, right );
          }
      }