What is the concept of null pointer in C language
This article mainly introduces "what is the concept of null pointer in c language". In daily operation, I believe that many people have doubts about the concept of null pointer in c language. The editor consulted all kinds of materials and sorted out simple and easy-to-use operation methods. I hope it will be helpful for you to answer the question of "what is the concept of null pointer in c language" Next, please follow the editor to study!
Description
1. If a pointer does not point to any data, we call it a null pointer.
2. Null is also null in C language, but it is not a data type, but a pointer, and null represents a null pointer.
The system ensures that the null pointer does not point to the actual object or function. In contrast, the address of any object or function cannot be a null pointer.
Example
Judgment that the pointer variable p is a null pointer:
If (p = 0) if (p ='0') if (p = 3-3) if (p = = NULL) / * the header file of the corresponding standard library must be included in the use of NULL * / if (NULL = = p) if (! p) if (p = Q) what C language is a process-oriented, abstract general programming language, widely used in low-level development Using C language, low-level memory can be compiled and processed in a simple way.
At this point, the study of "what is the concept of null pointer in c language" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!