Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class DebugMe {
- public static void main(String[] args) {
- Scanner scan = new Scanner(System.in);
- int statists = Integer.parseInt(scan.nextLine());
- double budget = Double.parseDouble(scan.nextLine());
- double pricePerCostume = Double.parseDouble(scan.nextLine());
- double decorPrice = budget * 0.1;
- budget *= 0.9;
- double clothesBudget = statists * pricePerCostume;
- if(statists > 150){
- clothesBudget *= 0.9;
- }
- budget -= clothesBudget;
- if(budget >= 0){
- System.out.println("Action!");
- System.out.printf("Windgard starts filming with %.2f leva left.", budget);
- }else{
- System.out.println("Not enough money!");
- System.out.printf("Windgard needs %.2f leva more.", Math.abs(budget));
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement