#include<stdio.h>
int main(){
float s=500;
int k;
int p;
printf("输入这个月员工的销售额:\n");
scanf("%d",&p);
if(p%1000==0){
k=p/1000;
}else{
k=p/1000+1;
}
switch(k){
case 0:
case 1:
case 2:break;
case 3:
case 4:
case 5:
s+=p*0.08;
break;
case 6:
case 7:
case 8:
case 9:
case 10:
s+=p*0.1;
break;
default:
s+=p*0.12;
break;
}
printf("员工这个月的工资是:%5.2f\n",s);
}
c语言计算工人工资
最新推荐文章于 2024-08-20 20:01:22 发布