Advertisement
Guest User

StudyHall

a guest
Jan 18th, 2019
85
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.49 KB | None | 0 0
  1. import java.util.Scanner;
  2.  
  3. public class Study {
  4.     public static void main(String[] args) {
  5.         Scanner scanner = new Scanner(System.in);
  6.  
  7.         double l = Double.parseDouble(scanner.nextLine());
  8.         double w = Double.parseDouble(scanner.nextLine());
  9.  
  10.  
  11.         double columns = Math.floor((w - 1) / 70);
  12.         double rows = Math.floor(l / 1.2);
  13.  
  14.         double all = columns * rows;
  15.  
  16.         double seats = all - 3;
  17.  
  18.         System.out.println(Math.floor(seats));
  19.     }
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement