假设已定义char ch[20],*str=ch; 下列哪条语句不正确_______________________。
A: str="teacher";
B: ch="teacher";
C: strcpy(ch, "teacher");
D: strcpy(str,"teacher");
A: str="teacher";
B: ch="teacher";
C: strcpy(ch, "teacher");
D: strcpy(str,"teacher");
举一反三
- 有说明:char ch[20] ,*str=ch ; 则语句ch="teacher" ; 能实现将字符串"teacher"赋值到ch数组 A: 正确 B: 错误
- 假设已定义char ch[20],*str=ch; 下列哪条语句不正确_______________________。 A: str="teacher"; B: ch="teacher"; C: strcpy(ch, "teacher"); D: strcpy(str,"teacher");
- Which of the following sentence means “The teacher is hard-working”? ( ) A: "The teacher",/ said that student,/ "is hard-working."/ B: The teacher said,/ "that student is hard-working."/
- 以下字符串定义错误的是___________。 A: char s[7]="Teacher"; B: char s[]="Teacher"; C: char s[10]={"Teacher"}; D: char s[10]="Teacher";
- 以下给字符数组str定义和赋值正确的是( ) A: char str[10]; str={"china!"}; B: char str[]={"china!"}; C: char str[10]; strcpy(str,"abcdefghijkl"); D: char str[10]={"abcdefghijkl"};