Original array is broken in two parts left and right array
int len1 = m - l + 1 , len2 = r - m ; int left [ len1 ] , right [ len2 ] ; for ( int i = 0 ; i < len1 ; i ++ ) left [ i ] = arr [ l + i ] ; for ( int i = 0 ; i < len2 ; i ++ ) right [ i ] = arr [ m + 1 + i ] ; int i = 0 ; int j = 0 ; int k = l ;