Project Name: Chpt2_Project Class Name: Chpt2_Project Write a Java program that calculates how fast a bucket will fill up. Step 1. Create an algorithm for the program (either a flowchart or pseudocode). You will have to submit the algorithm so make sure it is legible if drawn by hand. Step 2. Create a program in Eclipse that does the following. Inputs: The program must prompt the user for a size of the bucket and the flow rate of the water hose Enter the number of gallons the bucket will hold (this must be an integer): Enter the flow rate of the water hose in gallons per minute (this must be a double): Output: The program should have this output (below is an example): The bucket will be filled in the following number of minutes: Test data: Use the following data to test your program: The bucket will hold 5 gallons and the flow rate is 1.2 gallons per minute. Take a screen shot of your program running in Eclipse and paste it into a Word document. It should look like the image below. C2_Project (1) [Java Application] C:\Program Files\Javaljre1.8.0_131\bin\javaw.exe (Mar 13, 2019, 2:42:02 PM) Enter how many gallons the buckewill hold: 5 Enter the flow rate in gallons ber minute: 1.2 The bucket will be filled in che following number of minutes: 4.166666666666667

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

My homework is I have to write a java program that calculates how fast a bucket will fill up. I will attatch a document of the homework so you guys can see. I've written the java code up to the point where I am stuck now wondering if there is any math conversions that needed to be done because on the sample that was given, there are test numbers to put in and test and when I put in the same numbers to test in my code that I wrote in eclipse it doesn't come up with the same answer as the sample answer does. I will attatch my code also so you guys can compare and tell me if I am missing anything. Or maybe my code will work fine. Let me know.

 

Project Name: Chpt2_Project
Class Name: Chpt2_Project
Write a Java program that calculates how fast a bucket will fill up.
Step 1. Create an algorithm for the program (either a flowchart or pseudocode). You will have to
submit the algorithm so make sure it is legible if drawn by hand.
Step 2. Create a program in Eclipse that does the following.
Inputs: The program must prompt the user for a size of the bucket and the flow rate of the water hose
Enter the number of gallons the bucket will hold (this must be an integer):
Enter the flow rate of the water hose in gallons per minute (this must be a double):
Output: The program should have this output (below is an example):
The bucket will be filled in the following number of minutes:
Test data: Use the following data to test your program:
The bucket will hold 5 gallons and the flow rate is 1.2 gallons per minute.
Take a screen shot of your program running in Eclipse and paste it into a Word document. It should look
like the image below.
<terminated> C2_Project (1) [Java Application] C:\Program Files\Javaljre1.8.0_131\bin\javaw.exe (Mar 13, 2019, 2:42:02 PM)
Enter how many gallons the buckewill hold: 5
Enter the flow rate in gallons ber minute: 1.2
The bucket will be filled in che following number of minutes: 4.166666666666667
Transcribed Image Text:Project Name: Chpt2_Project Class Name: Chpt2_Project Write a Java program that calculates how fast a bucket will fill up. Step 1. Create an algorithm for the program (either a flowchart or pseudocode). You will have to submit the algorithm so make sure it is legible if drawn by hand. Step 2. Create a program in Eclipse that does the following. Inputs: The program must prompt the user for a size of the bucket and the flow rate of the water hose Enter the number of gallons the bucket will hold (this must be an integer): Enter the flow rate of the water hose in gallons per minute (this must be a double): Output: The program should have this output (below is an example): The bucket will be filled in the following number of minutes: Test data: Use the following data to test your program: The bucket will hold 5 gallons and the flow rate is 1.2 gallons per minute. Take a screen shot of your program running in Eclipse and paste it into a Word document. It should look like the image below. <terminated> C2_Project (1) [Java Application] C:\Program Files\Javaljre1.8.0_131\bin\javaw.exe (Mar 13, 2019, 2:42:02 PM) Enter how many gallons the buckewill hold: 5 Enter the flow rate in gallons ber minute: 1.2 The bucket will be filled in che following number of minutes: 4.166666666666667
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps with 1 images

Blurred answer
Knowledge Booster
Random Class and its operations
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education