RE: Fw: [Dev-C++] First experience with Dev-C++
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: Ioannis V. <no...@ya...> - 2002-01-23 19:38:55
|
> -----Original Message-----
> From: dev...@li...
> [mailto:dev...@li...] On Behalf
> Of Luigi Santillo
> Sent: Wednesday, January 23, 2002 6:09 PM
> To: dev...@li...
> Subject: RE: Fw: [Dev-C++] First experience with Dev-C++
>
> >...
> >
> > > #include <stdio.h>
> > > int main(int argc, char *argv[])
> > > {
> > > printf("Hello Dev-C++");
> > > return 0;
> > > }
> >
> >...
> >
> > > #include <iostream>
> > > #include <stdlib.h>
> > > int main(char * argv = new char [1024], int argc)
> > > {
> > > cout << "Hello Dev-C++";
> > >
> > > delete [] argv;
> > >
> > > float wait = 0;
> > > while (wait < 1E9) //see program notes
> > > wait++;
> > >
> > > return 0;
> > > }
> >
> >...
> >
> > > - is the order of the parameters correct in the first or in the
> > > second
> > version?
> >
> >The order of parameters doesn't matter.
>
> Probably my last question was not very clear. Here it is again.
>
> Which one of these is correct?
>
> int main(int argc, char **argv) {...} | int main(char
> **argv, int
> argc) {...}
>
> Or are the two forms both correct?
> In other words: the order of parameters does or does not matter)?
Oh that. Yes the order *does* matter.
Ioannis
* Ioannis Vranos
* Programming pages: http://www.noicys.d2g.com
* Alternative URL: http://run.to/noicys
|