单选题 C语言
题号 #2546671

有以下程序:
#include<stdio.h>
Struct stu
{  int hum;
char name[10];
int age;)
void fun(struct stu*p)
(print[(”%s\n”,(*p).name);)
main()
(
struct stu students[3]-}{9801.”Zhang”,20},
{9802,”Wang”,19},{9803,”Zhao”,18}}
fun(students+2):
}
输出的结果是(  )。

进入在线模考

参考答案

B

答案解析

B。【解析】从实参传递过去的是结构体系数组的第 3个元素,所以输出的name为Zha0。

你可能感兴趣的试题

找试题 · 找答案 · 找资料 在线模考