Advertisement
Guest User

Untitled

a guest
Mar 23rd, 2019
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.65 KB | None | 0 0
  1. import java.util.Scanner;
  2.  
  3. public class Dance {
  4.     public static void main(String[] args) {
  5.         Scanner scanner = new Scanner(System.in);
  6.  
  7.         double length = Double.parseDouble(scanner.nextLine());
  8.         double width = Double.parseDouble(scanner.nextLine());
  9.         double side = Double.parseDouble(scanner.nextLine());
  10.  
  11.         double hall = (length * 100) * (width * 100);
  12.         double wardrobe = (side * 100) + (side * 100);
  13.         double bench = hall / 10;
  14.         double freeSpace = hall - wardrobe - bench;
  15.         double dancers = freeSpace / (40 + 7000);
  16.  
  17.         System.out.printf("%.0f" , Math.floor(dancers));
  18.     }
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement