You are viewing a single comment's thread. Return to all comments →
To avoid errors such as "Unsafe operations",Use the following:-
ArrayList<ArrayList<Integer>> b=new ArrayList<ArrayList<Integer>>(n); for(int i=0;i<n;i++) b.add(new ArrayList<Integer>());
And to later on perform the operations, use expressions like:
int t=(a[i][1]^last)%n; b.get(t).add(a[i][2]);
Seems like cookies are disabled on this browser, please enable them to open this website
Dynamic Array
You are viewing a single comment's thread. Return to all comments →
To avoid errors such as "Unsafe operations",Use the following:-
And to later on perform the operations, use expressions like: