@Contract(pure=true)
  public static <T> T @NotNull [] remove(T @NotNull [] src, int idx) {
    int length = src.length;
    if (idx < 0 || idx >= length) {
      throw new IllegalArgumentException("invalid index: " + idx);
    }
    Class<T> type = getComponentType(src);
    T[] result = newArray(type, length - 1);
    System.arraycopy(src, 0, result, 0, idx);
    System.arraycopy(src, idx + 1, result, idx, length - idx - 1);
    return result;
  }
@Contract(pure=true)
  public static <T> T @NotNull [] remove(T @NotNull [] src, int idx)