I want to copy an array, but I don't know its size. I pasted the class and method below.
public MyClass {
private int map[][];
public void setMap(int[][] map){
//my code here
}
}
Of course, this way doesn't work. Because (as I said) I don't know the size.
int map[][] = new int[N][N];
for (int[] i : map)
for (int j : i)
i[j] = 1;