Is cin and cout are objects? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Is cin and cout are objects?

12th Aug 2017, 4:44 AM
Judy
Judy - avatar
5 Answers
+ 5
Yeah
12th Aug 2017, 4:53 AM
Rrestoring faith
Rrestoring faith - avatar
+ 5
@Judy as @Rrestoring said it is a yes. Cout and Cin are both objects. I am not sure if It will make sense to you. C++ has inner classes that make up the language like vector which is a class. Ostream and Istream are classes as well. cout is an object of the class Ostream cin is an object of Istream.
12th Aug 2017, 5:23 AM
Manual
Manual - avatar
+ 4
Yes they are objects. In fact they are respectively instances of istream and ostream classes.
12th Aug 2017, 5:19 AM
Michele Virgilio
Michele Virgilio - avatar
0
thanks
12th Aug 2017, 11:26 AM
Judy
Judy - avatar