public static <T> T[] copyOf(T[] original, int newLength) {if (original == null) {throw new NullPointerException();}if (newLength < 0) {throw new NegativeArraySizeException();}return copyOfRange(original, 0, newLength);}

public static < T > T [ ] copyOf ( T [ ] original , int newLength ) { if ( original == null ) { throw new NullPointerException ( ) ; } if ( newLength < 0 ) { throw new NegativeArraySizeException ( ) ; } return copyOfRange ( original , 0 , newLength ) ; }
public static int[] copyOf(int[] original, int newLength){if (newLength < 0){throw new java.lang.NegativeArraySizeException();}return copyOfRange(original, 0, newLength);}
