c++ make string array code example Example: c++ string with character array #include <cstring> strcpy(char_array, s.c_str());