Advertisement
Spocoman

Series Calculator

Sep 9th, 2024
502
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.57 KB | None | 0 0
  1. import java.util.Scanner;
  2.  
  3. public class Main {
  4.     public static void main(String[] args) {
  5.         Scanner scanner = new Scanner(System.in);
  6.         String series = scanner.nextLine();
  7.         int season = Integer.parseInt(scanner.nextLine()),
  8.                 volume = Integer.parseInt(scanner.nextLine());
  9.         double time = Double.parseDouble(scanner.nextLine()),
  10.                 minutes = (double) season * volume * time * 1.2 + season * 10;
  11.  
  12.         System.out.println("Total time needed to watch the " + series + " series is " + (int) minutes + " minutes.");
  13.     }
  14. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement