D:\>argtest this is a test programe of main()‘s argments You have inputed total 9 argments arg0 : D:\TC\NONAME.EXE arg1 : this arg2 : is arg3 : a arg4 : test arg5 : programe arg6 : of arg7 : main()‘s arg8 : argments The follow is envp : TMP=C:\WINDOWS\TEMP TEMP=C:\WINDOWS\TEMP PROMPT=$p$g winbootdir=C:\WINDOWS PATH=C:\WINDOWS;C:\WINDOWS\COMMAND COMSPEC=C:\WINDOWS\COMMAND.COM SBPCI=C:\SBPCI windir=C:\WINDOWS BLASTER=A220 I7 D1 H7 P330 T6 CMDLINE=noname this is a test programe of main()‘s argments ----------------------------------------------------------------------------------------- 命令行参数啊。argc 是参数的个数,argv[]是参数,argv[0]是文件名,argv[1]是第一个参数... 如你得exe文件名是:myprog.exe,那么 myprog 12 22 32 则argv[0]="myprog",argv[1]="12",argv[2]="22"...