填空题

设有下列的程序段:
char str[]="Hello";
char*ptr;
ptr=-str;
执行上面的程序段后,*(ptr+5)的值为______。

【参考答案】

’\0’
<上一题 目录 下一题>
热门 试题

单项选择题
下列程序的输出结果是( )。 #include<stdio.h> int fun(intx) int a; if(x==0‖x==1) return 3; else a=x-fun(x-2); return a; void main() printf( %d ,fun(7));
A.2
B.8
C.9
D.5
填空题
下列程序的功能:对输入的一行字符中的数字字符的字面值累加,输出此累加和,请填空。 #include<stdio.h> #include<ctype.h> main() char c; int a,s=0; while(______) if(isdigit(c)) a=c-’0’;s+=a; printf( s=%d ,s);
相关试题
  • 下列程序的输出结果是______。 #de...
  • 下列程序的运行结果是( )。 #include...
  • 若有定义int a[4][4]=1,2,3,...
  • 下列程序输出的结果是______。 int...
  • 设有下列程序: #include<stdio.h> ...