private static void mergeWithoutCopy(int[] from, int[] to, int lo, int mid, int hi)
   {
      // DK: cannot just return if mid >= a.length, but must still copy remaining elements!
      // DK: add two tests to first verify "mid" and "hi" are in range
      if (mid > from.length) mid = from.length;
      if (hi > from.length) hi = from.length;
      int i = lo, j = mid;
      for (int k = lo; k < hi; k++)
      {
         if      (i == mid)          to[k] = from[j++];
         else if (j == hi)           to[k] = from[i++];
         else if (from[j] < from[i]) to[k] = from[j++];
         else                        to[k] = from[i++];
      }
   }