Fare丶梦


私信TA

用户名:126913199

访问量:31045

签 名:

等  级
排  名 132
经  验 4890
参赛次数 0
文章发表 50
年  龄 22
在职情况 学生
学  校
专  业

  自我简介:

import java.util.Scanner;


public class Main {

        public static int wage(int a){

                if(a<=100000)

                        return (int) (a*0.1);

                else if(100000<a&&a<=200000)

                        return (int) (100000*0.1+(a-100000)*0.075);

                else if(200000<a&&a<=400000)

                        return (int) (100000*0.1+100000*0.075+(a-200000)*0.05);

                else if(400000<a&&a<=600000)

                        return (int) (100000*0.1+100000*0.075+200000*0.05+(a-40000)*0.03);

                else if(600000<a&&a<=1000000)

                        return (int) (100000*0.1+100000*0.075+200000*0.05+40000*0.03+(a-60000)*0.015);

                else

                        return (int) (100000*0.1+100000*0.075+200000*0.05+40000*0.03+60000*0.015+(a-1000000)*0.01);

        }

        public static void main(String[] arg){

                Scanner sc = new Scanner(System.in);

                int a = sc.nextInt();

                System.out.print(wage(a));

        }

}


 

0.0分

2 人评分

  评论区