Answers for "how to sum a 2d array in java"

0

how to sum a 2d array in java

for (int[] Array1 : Array) { //"Array" is the name of my array in this problem
            
	for (int colu = 0; colu < Array.length; colu++) { //"Colu" is the variable 
      												  //so change it on your 
      												  //code.
      sum = sum + Array1[colu];
    
	}
            
}
Posted by: Guest on June-10-2021

Code answers related to "Java"

Java Answers by Framework

Browse Popular Code Answers by Language