resize array in java

Solutions on MaxInterview for resize array in java by the best coders in the world

showing results for - "resize array in java"
Inès
30 Jun 2017
1int [] basedata = new int[10];
2
3int [] original = basedata;
4basedata = new int[12];
5
6for(int i = 0; i < original.length; i++){
7  basedata[i] = original[i];
8}