@@ -0,0 +1,699 @@
+import java.util.Scanner;%0A%0Apublic class Main %7B%0A%0A    public static void main(String%5B%5D args) %7B%0A%0A        Scanner sc = new Scanner(System.in);%0A%0A        while (true) %7B%0A%0A            int waterUsed = sc.nextInt();%0A%0A            if (waterUsed == -1) %7B%0A                break;%0A            %7D%0A%0A            int cost = 1150;%0A%0A            if (10 %3C waterUsed) %7B%0A                cost += Math.min((waterUsed - 10) * 125, 1250);%0A            %7D%0A%0A            if (20 %3C waterUsed) %7B%0A                cost += Math.min((waterUsed - 20) * 140, 1400);%0A            %7D%0A%0A            if (30 %3C waterUsed) %7B%0A                cost += (waterUsed - 30) * 160;%0A            %7D%0A%0A            System.out.println(4280 - cost);%0A%0A        %7D%0A%0A    %7D%0A%0A%7D%0A

Create : 0216