What is Pointer in c ?
Pointer : A pointer is a special type of variable that stores a memory address rather than a primitive value like int, char, float, etc. Usually , the address stored in the pointer is the address of some other variable. It is a variable that can hold the address if another variable.
Example :
int * ptr; /*declare a pointer variable which can store address of integer variables*/
ptr = &count; /*store the address of count in ptr. The unary operator ‘&’ returns the address of a variable */
Subscribe to:
Post Comments
(
Atom
)
No comments :
Post a Comment