以下程序的输出结果()。void main(){ char st[20]="hello\073\\\n"; printf("%d",strlen(st));}
A: 5
B: 7
C: 8
D: 9
A: 5
B: 7
C: 8
D: 9
举一反三
- 若有char st[20]="hello "; ,则执行printf("%d,%d ",strlen(st),sizeof(st)); 后的输出结果为()
- 以下程序的输出结果是:( )。 main() { char st[20]="hello\0\t\\"; printf("%d%d\n",strlen(st),sizeof(st)); }
- 以下程序的输出结果______。 main() { char st[20]="he11\O\t\"; printf("%d%d\n",str1en(st),sizeof(st)); } A: 99 B: 520 C: 1320 D: 2020
- 以下程序 #include <string.h> main() {char str[][20]={"Hello","Beijing"},*p=str; printf("%d ",strlen(p+20)); } 程序运行后的输出结果是
- 下面程序输出结果为:#includeiostreamusing namespace std;#includestring.hint main( ){ char st[20]=hello\0\t\\; coutstrlen(st); coutsizeof(st)endl; coutst; return 0;} A: 520hello B: 1220hello\0\t C: 520hello\t D: 1120hello└┘└┘