The System. Array class provided in C # is the base class of all Array types.
In C #, Arrays can be one-dimensional or multi-dimensional. arrays and uneven arrays are also supported.
Using System;
Class Test
{
Static void Main () // The length of the dynamically generated Array
{
String [] a1; // One-Dimensional string Array
String [,] a2; // two-dimensional
String [,] a3; // 3D
String [] [] j2; // variable array
String [] [] [] [] j3; // multidimensional variable array
}
}
Class Test2
{
Static void Main2 () // The length of the dynamically generated Array
{
Int [] a1 = new int [] {1, 2, 3 };
Int [,] a2 = new int [,] {1, 2, 3}, {4, 5, 6 }};
Int [,] a3 = new int [10, 20, 30];
Int [] [] j2 = new int [3] [];
J2 [0] = new int [] {1, 2, 3 };
J2 [1] = new int [] {1, 2, 3, 4, 5, 6 };
J2 [2] = new int [] {1, 2, 3, 4, 5, 6, 7, 8, 9 };
}
}
Referenced from:
Http://www2.cnblogs.com/netfork/archive/2004/03/22/3836.html