1 strcpy,
char * strcpy(char* target, char* source)
{ // 不返回const char*, 因为如果用strlen(strcpy(xx,xxx)),类型不匹配。
assert(source != NULL && target != NULL);
char* p = target;
while ((*target++ = *source++) != ' ') // 先赋值,然后用表达式和‘
1 strcpy,
char * strcpy(char* target, char* source)
{ // 不返回const char*, 因为如果用strlen(strcpy(xx,xxx)),类型不匹配。
assert(source != NULL && target != NULL);
char* p = target;
while ((*target++ = *source++) != ' ') // 先赋值,然后用表达式和‘