669.加薪
作者:
不想考试
,
2024-11-12 23:29:26
,
所有人可见
,
阅读 4
#include<cstdio>
#include<iostream>
using namespace std;
int main()
{
double x, y;
int z;
cin >> x;
if(x >= 0 && x <= 400) {y = x * 0.15;x = x * 1.15; z = 15;}
else if(x > 400 && x <= 800){y = x * 0.12;x = x * 1.12;z = 12;}
else if(x > 800 && x <= 1200){y = x * 0.10;x = x * 1.10;z = 10;}
else if(x > 1200 && x <= 2000){y = x * 0.07;x = x * 1.07;z = 7;}
else {y = x * 0.04;x = x * 1.04;z = 4;}
printf("Novo salario: %.2lf\n",x);
printf("Reajuste ganho: %.2lf\n",y);
printf("Em percentual: %d %\n",z);
return 0;
}