1 条题解

  • 0
    @ 2024-12-24 10:06:20

    C++ :

    #include<bits/stdc++.h>
    using namespace std;
    int main(){
    	double x;char c;
    	cin>>x>>c;
    	if(c=='y'){
    		if(x>300){
    			x=x-floor((x-300)/100)*20;
    		}
    		x*=0.95;
    	}else{
    		if(x>300){
    			x=x-floor((x-300)/100)*20;
    		}
    	}
    	printf("%.2lf",x);
    	return 0;
    } 
    
    • 1

    信息

    ID
    2738
    时间
    1000ms
    内存
    128MiB
    难度
    10
    标签
    递交数
    5
    已通过
    3
    上传者