char *name;
name=new char[strlen(n)+1];
Here what are we doing with the new operator?
Also n was passed to function as char *n, so which is basically a pointer to first element of char array right?
char *name;
name=new char[strlen(n)+1];
Here what are we doing with the new operator?
Also n was passed to function as char *n, so which is basically a pointer to first element of char array right?