谁能来帮帮我呀
查看原帖
谁能来帮帮我呀
1382592
Lanhening楼主2024/8/23 13:59

就差#3这一个点了

#include<iomanip>
#include<cmath>
using namespace std;
int main() {
    int T;
    cin >> T;
    if (T == 1) {
        cout << "I love Luogu!";
    } else if (T == 2) {
        cout << 2 + 4 << " " << 10 - 2 - 4;
    } else if (T == 3) {
        cout<<"3\n12\n2";
    } else if (T == 4) {
    	double h;
    	h=500.0/3.0;
        cout<<fixed<<setprecision(3);
        cout<<h;
    } else if (T == 5) {
        cout<<480/32;
    } else if (T == 6) {
        cout<<sqrt(6*6+9*9);
    } else if (T == 7) {
        cout<<"110\n90\n0";
    } else if (T == 8) {
        cout<<2*5*3.141593<<endl<<5*5*3.141593<<endl<<(double)4/3*3.141593*5*5*5;
    } else if (T == 9) {
       cout<<22;
    } else if (T == 10) {
        cout<<9;
    } else if (T == 11) {
        cout<<(double)100.0/3;
    } else if (T == 12) {
        cout<<13<<endl<<"R";
    } else if (T == 13) {
    	double a,b,c;
    	a=4.0/3.0*3.141593*4.0*4.0*4.0;
    	b=4.0/3.0*3.141593*10.0*10.0*10.0;
		c=pow(a+b,3.0);
		cout<<(int)(c);
    } else if (T == 14) {
        cout<<50;
    }
    return 0;
}
2024/8/23 13:59
加载中...