Is it possible to create an array of 2D int arrays like:
int n = 100;
int[][] [] a = new int[][] [n];
Array has a fixed length n and matrices (2D arrays) have different non-zero sizes (at least 1 x 1).
For performance I would like to store that in the stack, not like:
ArrayList<int[][]> a = new ArrayList<int[][]>(n);
which will be stored on the heap as far as I know.
[x+(length*y)]int[] a = new int[5]will be on the heap.. Alright, thanks for information, soArrayListis a solution.