#include<stdio.h>
#include<assert.h>
void my_strcpy(char* dest, char* src) {
//断言,src为NULL报错
assert(src != NULL);
while (*dest++ = *src++) {
;
}
}
int main() {
char arr[10] = { 0 };
char arr1[] = "hello bit";
my_strcpy(arr, arr1);
printf("%s", arr);
return 0;
}
03-02
317
04-23
3452