Answers

Question and Answer:

  Home  C Pointers

⟩ Tell me when is a void pointer used?

A void pointer is used for working with raw memory or for passing a pointer to an unspecified type.

Some C code operates on raw memory. When C was first invented, character pointers (char *) were used for that. Then people started getting confused about when a character pointer was a string, when it was a character array, and when it was raw memory.

 177 views

More Questions for you: