摘要: #include <string.h> int strcmp(const char *s1, const char *s2); 比较字符串s1和s2 int strncmp(const char *s1, const char *s2, size_t n); 比较字符串s1和s2前n个字符 int 阅读全文
posted @ 2018-12-09 12:38 kmist 阅读(8918) 评论(0) 推荐(0)
摘要: 字符串处理函数 1. 拷贝 strcpy 2. 追加 strcat #include <string.h> char *strcpy(char *dest, const char *src); 将字符串src 复制到字符数组 dest char *strncpy(char *dest, const 阅读全文
posted @ 2018-12-09 12:08 kmist 阅读(434) 评论(0) 推荐(0)