Q:

How to convert a string to character array?

I am new in C++ and I am sorry if this is a dumb question. My question is very simple someone please tell me how can I convert a string to character array?

A:

As per my knowledge you can simply call c_str method see the below code:
string test = "test string";
cout << "I am printing the first index of the character array" << test.c_str()[0];

Try this and let me know in case of any problem.

