C 字符串操作

1. strcat 拼接  【注意:拼接后的字符串长度不能超过字符串申请的内存空间长度,否则会报错】
char s1[30] = {'L', 'm', 'j', '', 'L', 'o', 'v', 'e', ''}; strcat(s1, "OC"); printf("%s", s1);
原文地址:https://www.cnblogs.com/swu-luo/p/4489167.html