8 formatString(
const std::string& format,
const std::vector<std::string>& args)
10 std::string formatted = format;
14 while ((pos = formatted.find(
"%s", pos)) != std::string::npos && argIndex < args.size())
16 formatted.replace(pos, 2, args[argIndex]);
17 pos += args[argIndex].length();