Answers for "how to assign a character array to a string c++"

C++
1

character array to string c++ stl

char arr[] = "mom";
std::cout << "hi " << std::string(arr);
Posted by: Guest on July-11-2021

Code answers related to "how to assign a character array to a string c++"

Browse Popular Code Answers by Language