string to char

  1. Create a C++ string.
  2. Convert C++ string to C-style string using string.c_str() method.