Q:

Find the width of a 2D array with a zero length

Imagine an array defined as follows:
int n = 10;
int[][] arr = new int[0][n];

Let's say this array is passed into several methods without preserving n. Can we obtain n from this array?
arr[0].length certainly won't work.

A:

Can we obtain n from this array?

No.
The way I think about it is this. The line
int[][] arr = new int[a][b];

is essentially the same as
int[][] arr = new int[a][];
for (int i = 0; i < a; i++)
    arr[i] = new int[b];

If a == 0, the for loop does nothing, so the value of b is irrelevant.

