Skip to main content

Write down about the three types of arrays.


One dimensional array :

A list of items can be given one variable name using only one subscript and such a variable iscalled a one dimensional array.

or,

One dimensional array :The array which is used to represent and store data in a linear from is called a one dimensional array.
=>Example :
int number[8];

Here in the example, 8 value of the variable number can be kept under the single variable number.


Two dimensional array :

When by using an array user can store two value, each for a row and a column under a variable, the array is then called a two dimensional array. Here, user can use infinite number of rows and columns.

or,

Two dimensional array :

The array which is used to represent and store data in a tabular from is called a one dimensional array.
Two dimensional arrays are declared as follows, type array_name[row size][column size];

Multidimensional array :

C allows arrays of three or more dimensions. The exact limit is determined by the compiler.
*Multidimensional arrays are often known as array of the arrays.

The general form of a multidimensional array is, type array_name[s1][s2]......[sn];

Where sn is the size of the dimension. For example,
int survey[6][8][14]
survey is a three dimensional array declared to contain 180 integer type elements.



Posted By -