6 条题解

  • 0
    @ 2023-5-30 13:47:21

    #include<bits/stdc++.h> using namespace std; int main() { double x,y; cin>>x; if (5>x && x>=0){ y=-x+2.5; } else if(10>x && x>=5){ y=2-1.5*(x-3)*(x-3); } else{ y=x/2-1.5; }

    cout<<fixed<<setprecision(3)<<y; return 0; }

    信我!

    信息

    ID
    609
    时间
    1000ms
    内存
    256MiB
    难度
    5
    标签
    (无)
    递交数
    355
    已通过
    143
    上传者