Answers for "how to iterate two dimensional arraylist in java"

0

how to iterate two dimensional arraylist in java

//using enhanced-for loop to iterate over two dimensional ArrayList
List<List<T>> items = new ArrayList<>(Arrays.asList(
                        Arrays.asList(T ...items),
                		Arrays.asList(T ...items1),
  						Arrays.asList(T ...items2)
					));

for (List<T> arr : items) {
    for (T item : arr) {
        System.out.print(item + " ");
    }
   System.out.println();
 }
Posted by: Guest on August-21-2021

Code answers related to "how to iterate two dimensional arraylist in java"

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language