I have an array of chars like this one:
char arr[3]=\"hi\"; cout << arr;// this will print out hi
So is the operator<< has an
Exactly in the same way as cout works.
cout
The array arr decays into pointer type, and there exists an overloaded version of istream as well which takes char* as argument. So arr gets passed to the operator>> as char* after decaying.
arr
istream
char*
operator>>