Types of pointer.

Types of pointer in C

Pointers are used to access the variables directly by using their address Locations. The value has been assigned to the variable gets stored in that particular memory location.
There are Eight different types of pointers, they are :

  1. Null pointer
  2. A pointer that is assigned NULL is called a "null pointer".The value of null pointer is 0.
  3. Void pointer
  4. A void pointer is also called as generic pointer. It doesn't have any standard data type. In this pointer void keyword is used. It is used to store the address of any variable.
  5. Wild pointer
  6. Pointers that are not initialized are called wild pointers.
  7. Dangling pointer
  8. A pointer that points to a memory location that has been deleted is called a dangling pointer.
  9. complex pointer
  10. Pointer to array Pointer to array of array Pointer to array of String Pointer to array of function Pointer to function Pointer to union Pointer to 2D array
  11. Near pointer
  12. Near pointer is used to store 16 bit addresses means within current segment on a 16 bit machine.
  13. Far pointer
  14. Far pointer is a 32-bit pointer, can access information which is outside the computer memory in a given segment.
  15. Huge pointer
  16. Huge pointer is same as far pointer is a 32-bit pointer, can access information which is outside the computer memory in a given segment. A huge pointer that is fixed.