Integer array of 4 elements
1000 1002 1004 1006
ARRAYS
An array is acollectionof variables of similar data type.
A specific element in an array is accessed by anindex.
Arrays may have from one to severaldimensions.
In C/C++, all arrays consist of contiguous memory locations.
The lowest address corresponds to the first elementand the highest address to the last element.
Single dimension Arrays
The general form declaring an array is<data type> <variable name>[size];
Eg:int marks[5];
The values are accessed by the indexes.
Eg:
marks[0]=90;marks[1]=95;marks[2]=98;marks[3]=85;marks[4]=80;
Recompense su curiosidad
Todo lo que desea leer.
En cualquier momento. En cualquier lugar. Cualquier dispositivo.
Sin compromisos. Cancele cuando quiera.