Array

Array:

It is a collection of variables belongings to the same data type. You can store group of data of similar data type in an array.
• Array might be belongs to any of the data types
• Array size must be a constant value.
• Always, Contiguous memory locations are used to store array elements in memory.
• If we do not know the size of array we initialize array to zero or null while declaration.

EXAMPLE FOR C ARRAYS:

• int p[10]; // integer array
• char q[10]; // character array i.e. string

DIFFERENT TYPES OF C ARRAYS:

There are 2 types of C arrays. They are,
1]One dimensional array
2]Multi dimensional array
2.1]Two dimensional array
2.2]Three dimensional array etc..

 

Leave a Reply

Your email address will not be published. Required fields are marked *