|
- #include <iostream>
- using namespace std;
- float c,r,a,sy,sz;
- int main()
- {
- c=10;
- r=c/3.14/2;
- a=c/4;
- sy=3.14*r*r;
- sz=a*a;
- if (sy>sz)
- cout<<"yuan";
- else cout<<"zheng";
- return 0;
- }[code]#include <iostream>
- using namespace std;
- float s,r,a,cy,lz;
- int main()
- {
- s=10;
- r=s/3.14/r;
- a=s/a;
- cy=r*3.14*2;
- lz=a*4;
- if (cy<lz)
- cout<<"yuan";
- else cout<<"zheng";
- return 0;
- }
复制代码 [/code] |
|