What will be the output of the following C code?1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16#include <stdio.h>
int main() {
int arr[] = {6, 7, 8, 9, 10};
int *ptr = arr;
*(ptr++) += 123;
printf("%d\n", *(ptr - 1));
printf("%d\n", *ptr);
printf("%d\n", *ptr, *(++ptr));
getchar();
return 0;
}
1 | 分析: |