Differences between structures and arrays

List out differences between structures and arrays

The following are the differences between structures and arrays:

- Array elements are homogeneous. Structure elements are of different data type.
- Array allocates static memory and uses index / subscript for accessing elements of the array. Structures allocate dynamic memory and uses (.) operator for accessing the member of a structure.
- Array is a pointer to the first element of it. Structure is not a pointer
- Array element access takes less time in comparison with structures.
Define macros. Advantages and disadvantages of Macros
A macro is a name given to a block of C statements as a pre-processor directive...
Pass by reference vs. pass by value
Pass by value always invokes / calls the function or returns a value that is based on the value....
Define static identifier in C
The static identifier is used for initializing only once, and the value retains during the life time of the program / application....
Post your comment
Discussion Board
ARRAY
NC 2
uwayezu anuarite 10-12-2016
cp
thank you for giving good differences between them
siribabu 05-14-2015
thank u!
your data ismore help full for me......
surbhi 03-25-2012