I want to copy a larger array that some elements randomly removed by remove()
method into the a small array.
I have used System.arraycopy()
but this method copies elements respectively. Therefore some elements in the larger array don't be copied.
I want to copy the larger array's all non-removed elements into small array which has the length is equal to number of non-removed elements in larger array.