How can I change a character of a string within an array of strings?
An execution error happens if I run the code below..
int main(int argc, char *argv[])
{
char *d[] = {"aaaa","bbbb","cccc"};
cout << d[2] << endl; //PRINT cccc
d[2][2] = 'x';
cout << d[2] << endl; // IT SHOULD BE PRINTED ccxc BUT AN EXECUTION ERROS HAPPENS
}
Grato