求解 78个错 !!!!!!!!!!!!!
javalady吧
全部回复
仅看楼主
level 2
逐日___ 楼主
public class Bonus
{
public static void main(String []args){
Scanner sc = Scanner(System.in);
double I = sc.nextDouble();
if (I<=100000)
{
System.out.println("发放奖金为:"+I*10%);
}
else(100000<=I<=200000)
{
double = b;
b = I-100000;
System.out.println("发放奖金为:"+b*7.5%+100000*10%);
}
else(200000<=I<=400000)
{
double = b;
b = I - 200000;
System.out.println("发放奖金为:"+b*5%+100000*10%+100000*7.5%);
}
else(400000<=I<=600000)
{
double = b;
b = I - 400000;
System.out.println("发放奖金为:"+b*3%+200000*5%+100000*7.5%+100000*10%);
}
else(600000<=I<=1000000)
{
double = b;
b = I - 6000000;
System.out.println("发放奖金为:"+b*1.5%+200000*3%+200000*5%+100000*7.5%+100000*10%);
}
else(I>=1000000)
{
double = b;
b = I - 1000000;
System.out.println("发放奖金为:"+b*1%+400000*1.5%+200000*3%+200000*5%+100000*7.5%+100000*10%);
}
}
}
2015年01月11日 11点01分 1
level 5
这。。。多重选择结构。怎么学的
2015年01月28日 18点01分 3
level 2
也是醉了。。。
2015年03月13日 08点03分 4
level 1
这种结构容易出问题,if else 多了。你看的都头晕了。用类试试。
2015年07月14日 13点07分 5
level 1
扫描仪没有new关键字 else后没if 条件不能连写应该用&&
2015年07月16日 10点07分 6
level 2
额。。。
2015年09月24日 16点09分 7
level 1
要注释啊,好杂
2015年10月08日 04点10分 8
level 1
这样写法不错才怪
2016年03月02日 06点03分 10
1