There is a second form that can be used to declare an array:
type[ ] var-name;
Here, the square brackets follow the type specifier, not the name of the array variable. For example, the following two declarations are equivalent:
The following declarations are also equivalent:
This alternative declaration form offers convenience when declaring several arrays at the same time. For example,
This creates three array ...