code: private static int[] expandAndFillWithAbsent(int[] array, int newSize) {
      int oldSize = array.length;
      int[] result = Arrays.copyOf(array, newSize);
      Arrays.fill(result, oldSize, newSize, ABSENT);
      return result;
    }
docs: Equivalent to {@code Arrays.copyOf(array, newSize)}, save that the new elements are ABSENT.