public static int [ ] insertArray ( int [ ] original , int index , int [ ] inserted ) { int [ ] modified = new int [ original . length + inserted . length ] ; System . arraycopy ( original , 0 , modified , 0 , index ) ; System . arraycopy ( inserted , 0 , modified , index , inserted . length ) ; System . arraycopy ( original , index , modified , index + inserted . length , modified . length - index - inserted . length ) ; return modified ; }
Inserts the specified array into the specified original array at the specified index .