没找到这个题,麻烦截个图或者放个链接
望采纳!!!点击回答右侧采纳即可!!我之前写的案例
string str = "Hello World!"; str.insert(6, "C++ "); cout << str << endl; // 输出:Hello C++ World!
string str = "Hello World!"; str.erase(6, 5); cout << str << endl; // 输出:Hello!
哦!谢谢。