Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Instructions Write the definition of a class swimmingPool, to implement the properties of a swimming pool. Your class should have the instance variables to store

Instructions Write the definition of a class swimmingPool, to implement the properties of a swimming pool. Your class should have the instance variables to store the length (in feet), width (in feet), depth (in feet), the rate (in gallons per minute) at which the water is filling the pool, and the rate (in gallons per minute) at which the water is draining from the pool. Add appropriate constructors to initialize the instance variables. Also, add member functions to do the following: determine the amount of water needed to fill an empty or partially filled pool, determine the time needed to completely or partially fill or empty the pool, and add or drain water for a specific amount of time, if the water in the pool exceeds the total capacity of the pool, output "Pool overflow" to indicate that the water has breached capacity. The header file for the swimmingPool class has been provided for reference. Write a program to test your swimmingPool class.

An example of the program is shown below: Pool data: Length: 30 Width: 15 Depth: 10 Total water in the pool: 0 To completely fill the pool: Enter water fill-in rate: 10 Time to fill the pool is approximately: 56 hour(s) and 6 minute(s). Make sure you are checking your work by running the tasks throughout your development process.

image text in transcribedimage text in transcribed

I need the screen shoot of the code please?

Instructions Write the definition of a class swimmingPool , to implement the properties of a swimming pool. Your class should have the instance variables to store the length (in feet), width (in feet). depth (in feet). the rate (in gallons per minute) at which the water is filling the pool, and the rate (in gallons per minute) at which the water is draining from the pool. Add appropriate constructors to initialize the instance variables. Also, add member functions to do the following: determine the amount of water needed to fill an empty or partially filled pool, determine the time needed to completely or partially fill or empty the pool, and add or drain water for a specific amount of time, if the water in the pool exceeds the total capacity of the pool, output "Pool overflow" to indicate that the water has breached capacity. The header file for the swimingPool class has been provided for reference. Write a program to test your swimmingPool class. An example of the program is shown below. Pool data: Length: 30 Width: 15 Depth: 10 Total water in the pool: 0 To completely fill the pool: Enter water f111 in rate: 10 ENGAGE | MINDTAP - M1 Programming Assignment 1: Swimming Pool * | Instructions \begin{tabular}{|l|l|l|} main.cpp & swimmingPool.h & swimmingPoollmp.cpp + \\ \hline 1 Write your code here \\ 2 \\ 3 \end{tabular} Lial the amount of water needed to fill an empty or partially filled pool, determine the time needed to completely or partially fill or empty the pool, and add or drain water for a specific amount of time, if the water in the pool exceeds the total capacity of the pool, output "Pool overflow" to indicate that the water has breached capacity. The header file for the swimmingPool class has been provided for reference. Write a program to test your swimmingPool class. An example of the program is shown below. Pool data: Length: 30 Width: 15 Depth: 10 Total water in the pool: 0 To completely f111 the pool: Enter water fill-in rate: 10 Time to fill the pool is approximately: 56 hour(s) ar Make sure you are checking your work by running the tasks throughout your development process

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data Management Databases And Organizations

Authors: Richard T. Watson

6th Edition

1943153035, 978-1943153039

More Books

Students also viewed these Databases questions

Question

Describe the major barriers to the use of positive reinforcement.

Answered: 1 week ago

Question

=+10. How are inflation and unemployment related in the short run?

Answered: 1 week ago

Question

=+8. Why is productivity important?

Answered: 1 week ago