#include<bits/stdc++.h>
using namespace std;
int main(){
double lev[10],after, before,tax[10],need[10], rate[10],remain;
lev[1] = 3500;
lev[2] = lev[1]+1500-45;
lev[3] = lev[2]+3000-300;
lev[4] = lev[3]+4500-900;
lev[5] = lev[4]+26000-6500;
lev[6] = lev[5]+20000-6000;
lev[7] = lev[6]+25000-8750;
lev[8] = 88430;
// if locate in lev[i], tax[i] has been payed.
tax[1] = 0;
tax[2] = 45;
tax[3] = tax[2]+300;
tax[4] = tax[3]+900;
tax[5] = tax[4]+6500;
tax[6] = tax[5]+6000;
tax[7] = tax[6]+8750;
// if locate in lev[i], need[i] has payed full taxes.
need[2] = 3500;
need[3] = 3500+1500;
need[4] = 3500+1500+3000;
need[5] = 3500+1500+3000+4500;
need[6] = 3500+1500+3000+4500+26000;
need[7]
【cpp】CSP 201612-2 工资计算
最新推荐文章于 2023-03-14 10:15:45 发布
本文介绍了如何使用C++解决CSP 201612-2题目的工资计算问题,涵盖了基本的算法和数据结构应用,包括员工工资的计算、奖金和扣税等复杂逻辑。
摘要由CSDN通过智能技术生成