When to use below two functions. Are there special cases in which one is preferred to use over other?
Arrays.copyOfRange() and System.arraycopy
I was looking here
int copied = Arrays.copyOf(arr, 10); //10 the the length of the new array
copied = Arrays.copyOf(arr, 3); // are they truncating new array copied size from 10 to 3 in this step???