Mail Archives: djgpp/1998/10/01/00:05:34
In article <36106661 DOT CAEE9F7B AT cartsys DOT com>, Nate Eldredge <nate AT cartsys DOT com>
writes:
>Dupheraire wrote:
>>
>> I just purchased a book on Object Oriented C++ that was written for Borland
>C++
>> 4.5 and Turbo C++. When I had programmed with C before the programs had
>> compiled and ran fine. I copied this simple program from the book:
>> #include <iostream.h> //(Had to change to stdio.h, which is
>probably
>> the //problem...)
There's a stray "the" that isn't commented.
>> voic main()
...and "void" is misspelled "voic". In ANSI C and C++, main must return an
integer. But other than that the program works fine in djgpp:
C:\ELC\src\cc .gxx -Wall Dupheraire.cc
C:\ELC\src\cc .a
yadda yadda yadda
C:\ELC\src\cc .cat Dupheraire.cc
#include <iostream.h>
int main()
{
cout << "yadda yadda yadda";
}
C:\ELC\src\cc .
>> {
>> cout << "yadda yadda yadda";
>> }
>> Do I need to find a library with the iostream header file, or do I just
>need to
>> dig up some cash and buy Borland C++? If the library is a available will
>> someone please
>> direct me to it? Thanks.
>
>If you installed the C++ package, you should have it. The file is
>gpp281b.zip. Remember to compile with `gpp' or you'll have more
>troubles.
- Raw text -