Allow me a bit of long-windedness in answering your question. I'm long-winded anyway
Think of a multi-dimensional array as a bunch of boxes of different sizes. Here's a 3-D array example:
Let's put 12 big boxes in a line on the floor.
In the first box, let's put 9 medium boxes.
In the second box, let's put 2 medium boxes.
In the third box, let's put 16 medium boxes.
Let's place nothing in any of the other big boxes.
In the first medium box in the first bog box, let's put 128 small boxes.
In the second medium box in the third big box, let's put 14 small boxes.
Let's place nothing in any of the other medium boxes.
Now, let's place figurines of circus animals in the first 76 small boxes in the first medium box of the first big box.
Finally, place figurines of circus animals in all 14 small boxes in the second medium box in the third big box.
Quite a mental image, isn't it? Let's simplify a little bit by translating to
Java Code:
What did we lean about multi-dimensional arrays from this? Take a look at lines 12-14. (In Java) A 3-dimensional array is nothing more than a 1-dimensional array that contains 2-dimensional arrays. So, in this example, the length of our 3-Dimensional array is 12, becuase it is a 1-Dimensional array that can contain 12 2-dimensional arrays. Likewise, the length of the 2-dimensional array that is the first sub-array (a3DArray[0]) is 9, because is is a 1-dimensional array that can contain 9 1-dimensional arrays.
Finally, note that a3DArray[10] is null. We didn't put any medium boxes in there, so there's nothing there. Also note that we can't put any figurines or small boxes in the big box; the compiler prevents us. Only medium boxes (2-D arrays) can go in the big box.
So, in Summary: