Sums, Counts, and Extremes in a 2D Array

The whole array
A gym records its visitors for four days, with one row per day and one column for each of three time slots: morning, afternoon, and evening.
int[][] visits = { {12, 30, 18},
{ 9, 25, 22},
{15, 41, 20},
{11, 28, 16} };
int total = 0;
for (int day = 0; day < visits.length; day++)
{
for (int slot = 0; slot < visits[day].length; slot++)
{
total += visits[day][slot];
}
}
Every element is visited once, and total ends at 247. The average visit count is total divided by the number of elements, 4 times 3, or 12. Both are int values, so total / 12 gives 20. Casting first, as in (double) total / 12, gives about 20.58.
The number of slots with more than 20 visitors uses the same two loops with an if around the update. Of the twelve values, 30, 25, 22, 41, and 28 are over 20, so the count is 5. Since 20 itself isn't more than 20, day 2's evening doesn't count.
One row or one column
A designated row takes one loop, with the row index written in. Day 2's total is
int day2 = 0;
for (int slot = 0; slot < visits[2].length; slot++)
{
day2 += visits[2][slot];
}
which adds 15, 41, and 20 to get 76. A designated column holds the column index still and lets the row index change. That loop runs once per row, so its bound is visits.length, even though the answer is about a column.
int most = visits[0][2];
for (int day = 1; day < visits.length; day++)
{
if (visits[day][2] > most)
{
most = visits[day][2];
}
}
This finds the busiest evening. The seed is the evening column's first element, so the loop starts at row 1, and most ends at 22, from day 1. A seed from somewhere else in the array could report a value that isn't in the evening column at all.
Busy days
The gym calls a day busy when it has more than 60 visitors. Counting busy days takes a total for each row and a test on each finished total. The total is declared between the two loops, so it starts over for every day, and it is tested after the inner loop ends.
int busyDays = 0;
for (int day = 0; day < visits.length; day++)
{
int sum = 0;
for (int slot = 0; slot < visits[day].length; slot++)
{
sum += visits[day][slot];
}
if (sum > 60)
{
busyDays++;
}
}
The day totals come out as 60, 56, 76, and 55. Only day 2 is over 60, so busyDays ends at 1. Day 0 has exactly 60, which doesn't count. Testing sum inside the inner loop instead would count partial totals, before a day was finished.