Run ID:156666

提交时间:2026-07-05 08:58:27

#include<bits/stdc++.h> using namespace std; int main() { char c; double price; cin >> c >> price; double ans; if(c == 'P') { ans = price * 0.7; } else if(c == 'G') { ans = price * 0.8; } else if(c == 'S') { ans = price * 0.9; } else { ans = price * 0.95; } printf("%.2f", ans); return 0; }