Using gcc

홍근식 darkstar@kslp.org
Fri Sep 14 09:28:00 GMT 2001


is ansi C
> Hello,
> 
> I am new to GNU CC and I have version gcc 3.0.1 running on Solaris 8. 
>  The package seemed to install okay and I added the  /usr/local/bin 
> directory to my path however, when I compile my c++ program it returns 
> the following message:
> 
>                     `main' must return `int'  
> 
> Here is the code.
> 
> #include <iostream.h>
> 
> void main()
> {
>        long   number = 0;
>        cout <<  "This is a test. "  <<  number   <<   endl;
> }
> 
> Is there a place where I get some sample c++ code that will compile to 
> test my install?
> 
> Thanks for your assistance.


-- 
°­ÇÏ°í ¾Æ¸§´Ù¿î ¸®´ª½º 
<a href=" http://darkstar.kslp.org" ;> http://darkstar.kslp.org </a>
<a href=" http://kslp.org" ;> http://kslp.org </a>



More information about the Gcc-help mailing list