char *p[4]={1,2,3,4}; 而输出是printf("%d",p[0]) ;printf("%d",p[1]) ;printf("%d",p[2]) 请问定义的*P[4] 是什么?还有为什么printf(“%d”,p[0]) 中是输出p[0] 而不是*p[0]呢?p[0]不是地址吗?答案输出的是:1 2 3

来源:学生作业帮助网 编辑:作业帮 时间:2024/05/10 08:24:26
char *p[4]={1,2,3,4}; 而输出是printf(

char *p[4]={1,2,3,4}; 而输出是printf("%d",p[0]) ;printf("%d",p[1]) ;printf("%d",p[2]) 请问定义的*P[4] 是什么?还有为什么printf(“%d”,p[0]) 中是输出p[0] 而不是*p[0]呢?p[0]不是地址吗?答案输出的是:1 2 3
char *p[4]={1,2,3,4}; 而输出是printf("%d",p[0]) ;printf("%d",p[1]) ;printf("%d",p[2]) 请问
定义的*P[4] 是什么?还有为什么printf(“%d”,p[0]) 中是输出p[0] 而不是*p[0]呢?p[0]不是地址吗?
答案输出的是:1 2 3

char *p[4]={1,2,3,4}; 而输出是printf("%d",p[0]) ;printf("%d",p[1]) ;printf("%d",p[2]) 请问定义的*P[4] 是什么?还有为什么printf(“%d”,p[0]) 中是输出p[0] 而不是*p[0]呢?p[0]不是地址吗?答案输出的是:1 2 3
p的值就是p[0]的地址
也就是p[0] = *p
那*p[0]是什么?