Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class Repainting {
- public static void main(String[] args) {
- Scanner scanner = new Scanner(System.in);
- int nylon = Integer.parseInt(scanner.nextLine());
- int paint = Integer.parseInt(scanner.nextLine());
- int thinner = Integer.parseInt(scanner.nextLine());
- int hours = Integer.parseInt(scanner.nextLine());
- double materials = (nylon + 2) * 1.50 + paint * 14.50 * 1.10 + thinner * 5 + 0.40;
- double workers = materials * hours * 0.30;
- System.out.println(materials + workers);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement