Mailinglist Archive: opensuse-programming (96 mails)

< Previous Next >
Re: [suse-programming-e] Undepricated gcc Hello World?
  • From: Tom Bradley <tbradley@xxxxxxxxxx>
  • Date: Fri, 28 Mar 2003 09:23:24 -0700
  • Message-id: <200303280923.24015.tbradley@xxxxxxxxxx>
the latest version of gnu c++ conforms more to the c++ standard. This standard
as dropped the .h so you need to use:

#include <iostream>
using namespace std;

for gcc3.1 and newer.


On Friday 28 March 2003 9:11 am, O'Smith wrote:
> On Friday 28 March 2003 02:13 am, Steven T. Hatton wrote:
> > I tried to write the most basic hello world program I know of in c++
> > and I am getting deprication messages from gcc when I compile.
> > Looking through the the documentation I have on line has merely lead
> > to several levels of indirection. What am I supposed to use insted
> > of <iostream.h>? And where do I find documentation on this which
> > won't take me an hour to figure out how to use basic standard in and
> > standard out?
> >
> > STH
>
> =====================
>
> Steven,
> This is my most basic "hello world" in c++. How does yours differ?
>
> #include <iostream.h>
>
> int main()
> {
> cout << "Hello World!\n";
> return 0;
> }
>
>
> Patrick

--
Tom Bradley
Software Engineer
Jaycor / Titan Systems


< Previous Next >