subsets of an array in java inbuilt methods code example Example: java subset of array Arrays.copyOfRange(array, 1, array.length);