Skip to main content

cin or cout objects in c++

C++ : As we know C++ is object oriented language. C++ used  objects and classes. Objects Cin and Cout  are used for standard input/output. As we we know in C language we used functions for input/output. But C++ used objects. Here Cin and Cout both are object to iostream class. which are used for read or write operations. Here we have an example for these objects:

 

In this example cout will print a message on console and cin will take input. Cout print output on screen. cout used instertion operator "<<" and cin used extraction operator ">>".

Comments