Here in this code, cout<<q<<endl;
is returning string "mani"?. q contain the address of first character 'm' so it should print address not string.please explain.
int main(){
char *q;
char b[5]={'m','a','n','i'};
q=&b[0];
cout<<b<<endl;
cout<<q<<endl;