C Data Types - Arrays

Arrays

For every type T, except void and function types, there exist the types “array of N elements of type T”.

An array is a collection of values, all of the same type, stored contiguously in memory. An array of size N is indexed by integers from 0 up to and including N-1.

For example:

int cat;

Arrays can be initialized with a compound initializer, but not assigned. Arrays are passed to functions by passing a pointer to the first element.

Read more about this topic:  C Data Types