✔ 最佳答案
#include
char * mystrcat(char * __restrict s, const char * __restrict append)
{
char * save = s;
for(; *s; ++s);
while(*s++ = *append++);
return(save);
}
//test program
int main (void){
char text[12] = "Hello";
puts(text);
puts(mystrcat(text, " world"));
return 0;
}
2007-04-10 03:54:48 補充:
修正 html 出唔到o既符號, 改為中文全形:#include<stdio.h>...char text[12] = ”Hello”; ...puts(mystrcat(text, ” world”)); ...