Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
147647 张晓冉 09优惠活动 C++ Accepted 0 MS 272 KB 456 2026-02-06 16:10:44

Tests(4/4):


Code:

#include<bits/stdc++.h> using namespace std; int main(){ char a; cin>>a; double x; cin>>x; if(a == 'P'){ x = x/10*7; cout<<fixed<<setprecision(2)<<x; }else if(a == 'G'){ x = x/10*8; cout<<fixed<<setprecision(2)<<x; }else if(a == 'S'){ x = x/10*9; cout<<fixed<<setprecision(2)<<x; }else{ x = x/10*9.5; cout<<fixed<<setprecision(2)<<x; } return 0; }