cout is not part of the C++ language. Just like printf() is not part of the C language. cout is an instance of the ostream class. printf() is a function. The C/C++ standard libraries are not part of either language they are merely an example of what one could do with the language.

The whole bitshifting thing has been explained already. I am going to suggest that you look in your C++ or some C++ tutorial for all the information about overloading operators.