In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-09-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Network Security >
Share
Shulou(Shulou.com)06/01 Report--
Pointers and operation rules pointing to array elements
A pointer to an array element is essentially the same as a pointer to a variable. Since each element in the array can be directly counted as a variable, the pointer to the array element, that is, the pointer to the variable.
Pointers to array elements are not difficult, but are commonly used. It will be more straightforward when we use the program to explain it.
Unsigned char number [10] = {0,1,2,3,4,5,6,7,8,9}; unsigned char * p
If we write p = & number [0]; then the pointer p points to element 0 of number, which assigns the address of number [0] to p, similarly, if we write p = & number [1]; p points to element 1 of the array number. P = & number [x]; where the size of x is 0,9, which indicates that p points to the x element of the array number. The pointer itself can also stop several complex operations, which are most frequently used in terms of pointers to array elements.
Analogy operation. The premise of comparison is that two pointers point to objects of the same type, such as two pointer variables p and Q, which point to an array of the same data type, then they can stop, > =, 0) {/ / when the data is to be sent, continue to send subsequent bytes SBUF = * ptrTxd; / / retrieve the data pointed to by the pointer cntTxd--; / / send counter plus ptrTxd++; / / send pointer increment}
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
The market share of Chrome browser on the desktop has exceeded 70%, and users are complaining about
The world's first 2nm mobile chip: Samsung Exynos 2600 is ready for mass production.According to a r
A US federal judge has ruled that Google can keep its Chrome browser, but it will be prohibited from
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
About us Contact us Product review car news thenatureplanet
More Form oMedia: AutoTimes. Bestcoffee. SL News. Jarebook. Coffee Hunters. Sundaily. Modezone. NNB. Coffee. Game News. FrontStreet. GGAMEN
© 2024 shulou.com SLNews company. All rights reserved.