// Lab1, problem 1, version 2. // Reading real numbers of type float from the keyboard. import java.util.Scanner; class Pool2 { final static int FlowRate = 70; final static float Capacity = 7.48f; public static void main (String[] args) { Scanner scan = new Scanner(System.in); System.out.print ("Enter the length of the pool: "); System.out.flush(); int length = scan.nextInt(); System.out.print ("Enter the width of the pool: "); System.out.flush(); int width = scan.nextInt(); System.out.print ("Enter the depth of the pool: "); System.out.flush(); int depth = scan.nextInt (); float volume = length * width * depth; float poolCapacity = Capacity * volume; float timeInMin = poolCapacity / FlowRate; System.out.println ("The time to fill the pool is " + timeInMin + " minutes."); } }