private void mergeArray(int start, int mid, int end) {
		if(mid<start || end<mid+1) {
			return;
		}
		int[] tmp = new int[end-start+1];
		int tmpIdx=0;
		int i = 0;
		int j = 0;
		
		while(i<mid-start+1&&j<end-mid) {
			if(array[start+i]<array[mid+1+j]) {
				tmp[tmpIdx++] = array[start+i];
				i++;
			} else {
				tmp[tmpIdx++] = array[mid+1+j];
				j++;
			}
		}
		while(i<mid-start+1) {
			tmp[tmpIdx++] = array[start+i++];
		}
		while(j<end-mid) {
			tmp[tmpIdx++] = array[mid+1+j++];
		}
		
		for(tmpIdx=0;tmpIdx<end-start+1;tmpIdx++) {
			array[start+tmpIdx] = tmp[tmpIdx];
		}
	}