string temp = "wfewfwfw\=====";
char cha1 = '\\';
temp = cha1;
printf("%s", temp); //程序会奔溃
const char* ch = temp.c_str();
cout << cha1 << endl;
replace_all(temp, "\\", "\\\\");
cout << temp << endl;
string不能接受的字符
猜你喜欢
转载自blog.51cto.com/haidragon/2327056
今日推荐
周排行