Sololearn: Learn to Code
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2
5th Apr 2019, 11:01 AM
Prokopios Poulimenos
Prokopios Poulimenos - avatar
0
Lone Wolf 7 , there's a method in <string> header called std::to_string(), it takes in an integer value and converts it to a string; Eg: std::string str=std::to_string(1000); Another way is to use 'static_cast' Eg: std::string str=static_cast<std::string>(100);
5th Apr 2019, 1:15 PM
Mensch
Mensch - avatar