自定义实现复制函数
/strcpy函数 void strCpy1(char dest[], char source[]) { int i = 0; while (source[i] != '\0') { dest[i] = source[i]; i++; } dest[i] = '\0'; } void strCpy2(char *dest, char *source) { while ((*dest++ = *source++) != '\0') { } } //strlen函数 unsigned long strLen(char str[]) { unsigned long length = 0; int i = 0; while (str[i] != '\0') { length++; i++; } return length; }