下面是这两个数字转换String道路。件:sstream


string num2str1(unsigned int num)
{
stringstream ss;
ss<<num;
return ss.str();
}

string num2str2(unsigned int num)
{
char str_[10];
sprintf_s(str_,"%d",num);
string str = str_;

return str;
}