2: Partial Array Initilization:: How To Access The Elements of An Array?
2: Partial Array Initilization:: How To Access The Elements of An Array?
int a[5]={10,15};
10 15 0 0 0
In general array_name[n-1] can be used to access nth element of an array. where n is any integer
number.
Example
float mark[5];
Suppose you declared an array mark as above. The first element is mark[0], second element
is mark[1] and so on.