慕勒3428872
c或c++的标准main function prototype:int main(void);int main();main();int main(int argc, char *argv[]);Unix和VC++的:int main(int argc, char *argv[], char *envp[]);int main(int argc, char* argv[]){/* argc是从屏幕输入的参数的个数,argv是输入参数的数组,这是C的标准main,记得最后要return */int a,b,sum;a=100,b=200;sum=a+b;printf("sum is %d\n",sum);/*假设文件名是test.exe,试试屏幕输入: test.exe Andy */if(argc > 0)printf("My name is %s", argv);return 0;/*一般0是表示正常返回,非0是异常*/}