If numbers is a two-dimensional int array that has been initialized and total is an int that has been set to 0, which of the following will sum all the elements in the array?
a. ```
for (int row = 1; row < numbers.length; row++)
{
for (int col = 1; col < numbers.length; col++)
total += numbers[row][col];
}```
b.``` for (int row = 0; row < numbers.length; row++)
{
for (int col = 0; col < numbers.length; col++)
total += numbers[row][col];
}```
c. ```for (int row = 0; row < numbers[row].length; row++)
{
for (int col = 0; col < numbers.length; col++)
total += numbers[row][col];
}```
d. ```
for (int row = 0; row < numbers.length; row++)
{
for (int col = 0; col < numbers[row].length; col++)
total += numbers[row][col];
}
```
d.```
for (int row = 0; row < numbers.length; row++)
{
for (int col = 0; col < numbers[row].length; col++)
total += numbers[row][col];
}
```
You might also like to view...
The simplest of the File constructors takes a String parameter giving the name of the file.
Answer the following statement true (T) or false (F)
What is the file containing the program called after it has been translated into machine language?
What will be an ideal response?
Unless changed, Word automatically checks your spelling as you type
Indicate whether the statement is true or false
The ___________________ option of the SizeMode property adjusts the size of the PictureBox object to fit the image precisely.
Fill in the blank(s) with the appropriate word(s).