摘要: 字符串拷贝 strncpy(): char * strncpy(char*dest, char *src, size_t n);控制拷贝长度,更加安全 strDestination strlen(strDestination):从strDestination后开始 strncpy(strDestin 阅读全文
posted @ 2017-01-03 16:21 糯米米一粒 阅读(111) 评论(0) 推荐(0) 编辑
摘要: int转string一、#include <sstream> int n = 0; std::stringstream ss; std::string str; ss<<n; ss>>str; 二、#include <string> to_string(num); string转int std::s 阅读全文
posted @ 2017-01-03 16:13 糯米米一粒 阅读(115) 评论(0) 推荐(0) 编辑