Does C# supports multi-dimensional arrays?
Answer Posted / anand
Yes in addition to single-dimensional arrays, C# supports
the declaration of multidimensional arrays where each
dimension of the array is separated by a comma. Here I'm
declaring a three-dimensional array of doubles: -
double[,,] numbers;
Examples:
currentMonth=10;
sales = new double[2, currentMonth];
for (int i = 0; i < sales.GetLength(0); i++)
{
for (int j=0; j < 10; j++)
{
sales[i,j] = (i * 100) + j;
}
}
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
List down the commonly used types of exceptions in .net
How to update the gui from another thread in c#?
Explain the different types of delegates used in c#.
What is public or shared assemblies ?
What is difference between override and new in c#?
Does unity use c++ or c#?
how to compare numbers and dispaly the largest ? *first thing I wanted to do is to input how many numbers to be compared *and then analyzed the largest then display it.
Explain the difference between class and interface in .net?
What is a generic in c#?
What are the 2 broad classifications of fields in c#?
Explain jagged arrays in c#?
What are functions in c#?
What is overloading with example?
What is type checking in c#?
What is activator c#?