Hello I am beginner in c++ , can someone explain to me this
char a[]="Hello";
char b[]=a; // is not legal
whereas,
char a[]="Hello";
char* b=a; // is legal
If a array cannot be copied or assigned to another array , why is it so that it is possible to be passed as a parameter , where a copy of the value passed is always made in the method
void copy(char[] a){....}
char[] a="Hello";
copy(a);
pass by referencestd::vectorwhich has the behaviour that arrays do in most high-level languages.char *a. Calling this pass by reference conflicts with actually passing by reference, via the parameter being a reference (i.e. it has the&).