int[,] r1 = { { 1, 2, 3 }, { 9, 8, 7 } };
for(int i = 0; i < r1.GetLength(0); i++)
{
for (int j = 0; j < r1.GetLength(1); j++)
{
Console.Write($"{r1[i,j]}");
}
Console.WriteLine();
}
Gets a 32-bit integer that represents the number of elements in the specified dimension of the Array.