what is difference between array and structure?
Answer Posted / chaudhary paresh
- 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.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What are linked lists in c?
What is wrong with this code?
What is omp_num_threads?
What is the difference between array and linked list in c?
How can I sort a linked list?
int main() { Int n=20,i; For(i=0;i<=n;i--) { Printf(“-“); Return 0;
Can a void pointer point to a function?
If the size of int data type is two bytes, what is the range of signed int data type?
what is different between auto and local static? why should we use local static?
What is the use of header?
Is sizeof a keyword in c?
The statement, int(*x[]) () what does in indicate?
Why malloc is faster than calloc?
What is sizeof array in c?
Here is a neat trick for checking whether two strings are equal