This is a bit verbose to my taste:
ostrstream ss;
ss << "Selected elements: " << i << "," << j << ".";
string msg(ss.str(), (size_t)ss.pcount());
Is there an elegant way to format a text message using a concise one-line statement perhaps with templates or macros?