Java tutorial
//package com.java2s; import java.util.Arrays; public class Main { public static <T> T[] splice(T[] arr, int start, int end) { int size = end - start; T[] newArr = Arrays.copyOf(arr, size); System.arraycopy(arr, start, newArr, 0, size); return newArr; } }