C language --- pointer written test questions
Question 1:
(& A) gets an array pointer such as int(*)[5]. Then + 1 skips the whole array and points to the position after 5.
*(a+1)=a[1]=2; * (ptr-1) = skip an element to point to 5
int main(){
int a[5] = { 1, 2, 3, 4, 5 };
int* ptr = (int*)(&a + 1);
printf("%d,%d", *(a + 1), *(ptr - 1));
Question 2:
1. Th ...
Posted by scheibyem on Mon, 25 Oct 2021 05:54:05 -0700
Jump between Android app development activities (job 2)
Jump between Android app development activities (job 2)
Purpose of the experiment: (1) Click and jump the page with recycleView. For example, if a tab page is a news list, click a line to jump to the news details page; (2) The basic principle of this assignment is to understand the life cycle of activity and state transition operation;
1, ...
Posted by raister on Mon, 25 Oct 2021 05:44:03 -0700
STM32 communicates through serial port (assembly)
1. UART introduction
Universal synchronous asynchronous receiver and transmitter is a A serial communication device, which can flexibly exchange full duplex data with external devices. There is another difference from USART UART(Universal Asynchronous Receiver and Transmitter) cuts out the same data on the basis of USART Step communication ...
Posted by D1proball on Mon, 25 Oct 2021 04:59:12 -0700
Working principle of nginx and configuration of nginx
Working principle of nginx and configuration of nginx
1. Working principle of nginx
Nginx modules are directly compiled into nginx, so they belong to static compilation.
After starting nginx, the module of nginx is loaded automatically. Unlike Apache, first compile the module into a so file, and then specify whether to load it in the configu ...
Posted by dbrown on Mon, 25 Oct 2021 04:34:17 -0700
Notes - javase common classes
1.String class The String class is immutable and cannot be modified after the String object is declared. String s1 = "a"; String s2 ="b"; s1= s1+s2; ...
Posted by sublevel4 on Mon, 25 Oct 2021 04:33:08 -0700
Reconstructing document approval items with DDD (Domain Driven Design) -- continued
I wrote an article like the title of this article before, but considering that the length does not introduce the reconstruction process of the project, I will fill in this pit today to solve a heart disease.
If you want to use DDD, relevant knowledge is essential, so first recommend sev ...
Posted by bqallover on Mon, 25 Oct 2021 04:06:34 -0700
Detailed explanation of single linked list of data structure
Linked list of data structure
----------------------------------------------------------Daily chart--------------------------------------------------
preface
In the last article, we analyzed and explained the function and implementation of linear table. In fact, linear table has many disadvantages. In this article, we will explain ...
Posted by dksmarte on Mon, 25 Oct 2021 02:38:43 -0700
Working principle and configuration of nginx
Working principle and configuration of nginx
Module and working principle of nginx
Nginx consists of kernel and modules. Among them, the design of the kernel is very small and concise, and the work completed is also very simple. Only by looking up the configuration file, the client request is mapped to a location block (location is an ins ...
Posted by ChrisMayhew on Mon, 25 Oct 2021 01:59:12 -0700
Access Google payment 4.0 (Kotlin)
preface
Many game R & D students may need to access Google to pay. We all know the Google Documents. Sometimes it seems that they have grasped something but haven't grasped anything, resulting in the access work sometimes falling into a bottleneck. I sorted out the next Google payment interface, and added some explanatory text and extensio ...
Posted by ronz on Mon, 25 Oct 2021 01:46:17 -0700
Summary of mixed programming problems of C and C + +
1. When to mix c and c + + code?
Here are some key points:
1. When compiling main(), you must use the C + + compiler (for example, for static initialization)2. Your C + + compiler should guide the linking process (for example, so that it can get its special library)3. Your C and C + + compilers may need to be from the same vendor and have com ...
Posted by ChrisA on Mon, 25 Oct 2021 01:36:01 -0700