Solved

C++ cout object

Posted on 2001-08-03
4
311 Views
Last Modified: 2010-04-02
In every C++ program for displaying any value on console
we are using 'cout' object.but we are not creating this object  any where in our program.where this object has been declared?
0
Comment
Question by:sita
  • 2
4 Comments
 
LVL 22

Accepted Solution

by:
nietod earned 50 total points
ID: 6348282
Yes.

It is declared in the standard include file <iostream> or in an include file that that includes.

0
 
LVL 22

Expert Comment

by:nietod
ID: 6348298
For example, in the <iostream> that comes with VC 6, it is declared like

extern _CRTIMP ostream cout;

This declares it as an ostream object that has been externally defined.  That is, this says that the program being compiled has not and will not define cout, but cout is defined in some library that will be linked into it.
0
 
LVL 11

Expert Comment

by:griessh
ID: 7021997
Dear sita

I think you forgot this question. I will ask Community Support to close it unless you finalize it within 7 days. You can always request to keep this question open. But remember, experts can only help you if you provide feedback to their questions.
Unless there is objection or further activity,  I will suggest to accept

     "nietod"

comment(s) as an answer.

If you think your question was not answered at all, you can post a request in Community support (please include this link) to refund your points. The link to the Community Support area is: http://www.experts-exchange.com/commspt/

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
======
Werner
0
 
LVL 6

Expert Comment

by:Mindphaser
ID: 7040370
Force accepted

** Mindphaser - Community Support Moderator **
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

IntroductionThis article is the second in a three part article series on the Visual Studio 2008 Debugger.  It provides tips in setting and using breakpoints. If not familiar with this debugger, you can find a basic introduction in the EE article loc…
C++ Properties One feature missing from standard C++ that you will find in many other Object Oriented Programming languages is something called a Property (http://www.experts-exchange.com/Programming/Languages/CPP/A_3912-Object-Properties-in-C.ht…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question