by adrianmsmith · 3y ago · 0 comments
The way you've phrased it is a bit ambiguous.
Having 0 dimension sounds like
x = new int[7][5]; // 2 dimensions
y = new int[9]; // 1 dimension
z = new int; // no dimensions, not an array, not allowed
The phrasing you mean is "dimensions can have zero size".> (It’s somewhat counterintuitive that the zero dimension is not the first one in the array.)
"Dimensions" plural agrees with "zero" as a count, so that reads as "the count of dimensions is zero".
But they used singular "dimension" with "the" which treats "zero" as an adjective. It means "the dimension that is zero".
Out of curiosity, how do you rate each of:
"Arrays can have a zero dimension."
"Arrays can have two zero dimensions."
"Arrays can have some zero dimensions."
"Arrays can have zero dimensions."
in this regard?
So yeah, my description above is a bit off, I guess it's the articles that do it? Is "some" considered an article?