【C语法】字符串相加

//把str1放到str2后,即str2+str1

char str1[10]="world!";
char str2[20]="Hello ";
strcpy(str2+strlen(str2),str1);
printf("%s",str2);

//输出将是:Hello world!

原文地址:https://www.cnblogs.com/caixu/p/1921222.html