static void AuxillaryMergeSort(int[] A, int[]B, int p, int r) {
       
	   if (p < r) {
		   
		   if((r-p)>11){ 
			   
			   int q = p + ((r-p)>>1);// Get the medium element by shifting
			   AuxillaryMergeSort(A, B, p, q);
			   AuxillaryMergeSort(A, B, q+1, r);
			   AuxillaryMerge(A, B, p, q, r);
			   
		   } else {  // Insertion sort
				for(int i=p, j=i; i<r; j=++i) {
				    int ai = A[i+1];
				    while(ai < A[j]) {
				    	A[j+1] = A[j];
				    	if (j-- == p) {
				    		break;
				    	}
				    }
				    A[j+1] = ai;
				}
		   	}
        }
    }