Array is collection of homogenious data stored under unique name. The values in an array is called as 'elements of an array'. These elements are accessed by numners called as 'Subscripts or index numbers.' Arrays may be of any variable type.
Array is also called as 'Subscripted variable.'
The array which is used to represent and store data in a linear form is called as 'Single or One Dimensional Array.'
< data_type > < array_name >[size];
int a[3] = { 2, 3, 5 }
char ch[20] = "TechnoExam";
float stax[3] = { 5003.23, 1940.32, 123.20 }
total size = length of array * size of data type
-----------------In above example, a is an array of type integer which has storage size of 3 elements. The total size would be 3 * 2 = 6 bytes
* Memory Allocation:

#include< studio.h > #include< conio.h > void main() { int a[3], i; clrscr(); printf("\n\t Enter three numbers:"); for(i=0; i<3; i++) { scanf("%d", &a[i]); // read array } printf("\n\n\t Numbers are :"); for(i=0; i<3; i++) { printf("\t %d", a[i]); // print array } getch(); } Output: Enter three numbers: 9 4 6 Numbers are: 9 4 6
The array which is used to represent and store data in a tabular form is called as TWO DIMENSIONAL ARRAY. such type of array specially used to representn data in a matrix form.
The following syntax is used to represent two dimensional array.
Syntax:
< data-type > < array_nm >[row_subscript][Column-subscript];
Example
int a[3][3];
In the above example, 'a' is an array of type integer which has storage size of 3 * 3 matrix. The total size wpuld be 3 * 3 * 2 18 bytes.
It is also called 'multidimensional array.'
* Memory Allocation:

#include< stdio.h > #include< conio.h > void main() { int a[3][3], i, j; clrscr(); printf("\n\t Enter matrix of 3 * 3 : "); for(i=0; i<3; i++) { for(j=0; j<3; j++) { scanf("%d", &a[i][j]); // read 3 * 3 matrix } } printf("\n\tMatrix is : \n"); for(i=0; i<3; i++) { for(j=0; j<3; j++) { printf("\t %d", a[i][j]); // print 3 * 3 array } } getch(); } output: Enter matrix of 3 * 3 : 3 4 6 7 2 1 2 3 Matrix is: 3 4 5 6 7 2 1 2 3