continue;// 当等于给定下标值时,不进行复制
} else {
newIndex += 1;
newArray[newIndex] = array[i];
}
}
} else {
throw new ArrayIndexOutOfBoundsException("下标值应该大于等于零且小于" + array.length);
}
}
return newArray;
}
continue;// 当等于给定下标值时,不进行复制
} else {
newIndex += 1;
newArray[newIndex] = array[i];
}
}
} else {
throw new ArrayIndexOutOfBoundsException("下标值应该大于等于零且小于" + array.length);
}
}
return newArray;
}
转载于:https://www.cnblogs.com/quanby/p/5392516.html