In C++ cout is:
a) object
b) class
c) something else
Answer Posted / chandra
cout is an object of class ostream that represents the
standard output stream. It corresponds to the cstdio stream
stdout.
By default, most systems have their standard output set to
the console, where text messages are shown, although this
can generally be redirected.
Because cout is an object of class ostream, we can write
characters to it either as formatted data using for example
the insertion operator (ostream::operator<<) or as
unformatted data using the write member function
Is This Answer Correct ? | 21 Yes | 1 No |
Post New Answer View All Answers
Can recursive program be written in C++?
Explain terminate() function?
What is flag in computer?
Define the process of error-handling in case of constructor failure?
What is virtual destructor? What is its use?
When you overload member functions, in what ways must they differ?
What is the protected keyword used for?
Write a program for Divide a number with 2 and Print the output ( NOTE: Check for divide by zero error).
I was a c++ code and was asked to find out the bug in that. The bug was that he declared an object locally in a function and tried to return the pointer to that object. Since the object is local to the function, it no more exists after returning from the function. The pointer, therefore, is invalid outside.
Which bitwise operator is used to check whether a particular bit is on or off?
What is different in C++, compare with unix?
Discussion on error handling of C++ .
Show the declaration for a pointer to function returning long and taking an integer parameter.
How static variables and local variablesare similar and dissimilar?
Explain about templates of C++.