提交时间:2019-10-13 10:26:18

运行 ID: 1521

#include<iostream> int main(){ int a,b; double c; scanf("%d,%d",&a,&b); switch (a){ case 1: c=b*0.0225+b;break; case 2: c=(b*0.0243*2)+b;break; case 3: c=(b*0.027*3)+b;break; case 4: c=(b*0.0288*4)+b;break; default :c=(b*0.03*5)+b;break; } printf("合计为%lf",c); return 0; }