//This method has potential for some micro-optimizations. Somebody *please* //convince me *not* to do them. void arg(const string& a) { if (next_arg >= 9) { return; } size_t offset = offsets[next_arg]; str.erase(offset, 2); //erase the placeholder str.insert(offset, a); //insert the new string in place next_arg++; }