nyoj-球的体积

mac2022-07-01  8

四舍五入的技巧

#include <iostream>using namespace std;const double PI = 3.1415926;int main(){    float r;    while(cin >> r)    {              cout << int(4*PI*r*r*r/3 +0.5) << endl;              }    return 0;}

转载于:https://www.cnblogs.com/ekinzhang/p/4374444.html

相关资源:数据结构—成绩单生成器
最新回复(0)