Inserting
Inserting characters into an existing string can be done via the insert() function.
string& string::insert (size_type index, const string& str) string& string::insert (size_type index, const char* str)
Both functions insert the characters of str into the string at index Both function return *this so they can be “chained”. Both functions throw out_of_range if . . . → Read More: 17.7 — std::string inserting