Mail Archives: djgpp/1998/01/27/06:05:34
ruleboy AT weblock DOT tm DOT net DOT my wrote:
> #include <io.h>
> main ()
> {
> int x, y, sum;
> cout<<"\nEnter first number: ";
> cin>>x;
> cout<<"\nEnter second number:";
> cin>>y;
> sum = x + y
> cout<<"\nSum = "<<sum;
> return 0;
> }
> and what i got?
> i got this : 1. cout, undeclared (first use this function)
> 2. each identifier is reported only once
> 3. for each function it appears in
> 4. cin undeclared (first use this function)
> So, basically i have some problems with the header files, and
> actually i can't run anything if this thing stays like that.
Why do you include io.h when in fact you want to
include iostream.h?
And why do you answer your problems in the subject line?
So, just include iostream.h and live happily
ever after.
--
Ciao
Tom
*************************************************************
* Thomas Demmer *
* Lehrstuhl fuer Stroemungsmechanik *
* Ruhr-Uni-Bochum *
* Universitaetsstr. 150 *
* D-44780 Bochum *
* Tel: +49 234 700 6434 *
* Fax: +49 234 709 4162 *
* http://www.lstm.ruhr-uni-bochum.de/~demmer *
*************************************************************
- Raw text -