Difference Between Array and Pointer in c

No comments



Array V/S Pointer :


Array
Pointer
1 . Array allocates space automatically.
1 . It is explicit assigned to point to an allocated space.
2 . It cannot be resized.
2 . It can be resized using realloc ( ).
3 . It cannot be reassigned.
3 . It can be reassigned.
4 . Sizeof(arrayname) gives the number of bytes occupied by the array.
4 . Sizeof(p) returns the number of bytes used to store the pointer variable p.

No comments :

Post a Comment

Subscribe

Milan Panda
Admin
About Me | Contact
Copyright 2023-2024 © Programming1011 . 🎀 Developed and Design By- Milan Panda. Happy Holi All Of You 🎀