- 0
- 0
- 约1.16万字
- 约 12页
- 2018-07-08 发布于江苏
- 举报
c++面向对象编程试验 源程序(原解) 实验内容? 二、编写函数实现最大公约数的求取。?//---------------------------------------------------------------------------#pragma hdrstop//---------------------------------------------------------------------------#pragma argsused#includestdio.h#includeiostream.hint main(int argc, char* argv[]){???????? int x,y,t;???????? int i,j;???? coutplease input x,y:endl;???? cinxy;if(xy){t=x;x=y;y=t;}???? for(i=2.0;ix;i++)???? if(x%i==0)?????? {?????????? if(y%x==0) j=x;???????????? else if(y%i==0)? j=i;?????? }?????? coutzuida gongyue shu:j;??????? if(ix)? coutcant find!endl;??????? re
原创力文档

文档评论(0)