Question: REQUIREMENTS DOCUMENT Date: March 17, 2019 Date Submitted: Application Title: Most Rainfall in the USA Purpose: This Windows Classic Desktop application is written for Kauai,
REQUIREMENTS DOCUMENT Date: March 17, 2019 Date Submitted: Application Title: Most Rainfall in the USA Purpose: This Windows Classic Desktop application is written for Kauai, Hawaii, the rainiest location in the United States, to compute the average monthly amount of rainfall per year. Program Procedures: In a Windows application, the user enters up to 12 values representing the number of inches of rain cach month to compute the average rainfall in a given number of months or a full year. Algorithms, 1. In an InputBox object, the user enters up to 12 amounts of rainfall per month in Processing, and inches. Conditions: 2. Each amount of rainfall per month is displayed in the ListBox object. 3. After 12 entries of rainfall values are entered, the average rainfall is calculated and displayed. 4. A File menu contains a Clear and an Exit option. The Clear menu item clears the average rainfall and the 12 values representing the amount of rainfall per month in Kauai. The Exit menu item closes the application. 5. If the user clicks the Cancel button in the input box before entering 12 values, compute the average amount of rainfall entered. 6. If the user clicks the Cancel button before entering any rainfall values, display a message indicating the user did not enter a value. Notes and 1. Nonnumeric values should not be accepted. Restrictions: 2. Negative values should not be accepted. 3. The average rainfall should be rounded to the nearest tenth of an inch. Comments: 1. The application allows decimal entries. 2. Obtain a background image for this program from Cengage Brain.com. The name of the image file is hawaii. FIGURE 6-114 rUSE CASE DEFINITION 1. The Windows application opens with the heading "Most Rainfall in US - Kauni," a ListBox object that displays the monthly rainfall amounts, an image, and a Button object that allows the user to begin entering their rainfall amounts in inches. 2. A menu bar displays the File menu, which has two menu items Clear and Exit. 3. The user enters up to 12 monthly values in an InputBox object, with each value representing the number of inches of rainfall per month in Kauai. 4. The program asks the user for the rainfall amount again if the value is a negative number or the entry is a nonnumeric value. 5. The program displays the average inches of rainfall rounded to one decimal place. 6. The user can clear the input and the result by clicking the Clear menu item, and then can repeat Steps 3-5. If the user clicks the Cancel button in the input box, the average for the values entered is calculated. If the user did not enter any values, the program displays an appropriate message. 7. The user clicks the Exit menu item to close the application. FIGURE 6-115 r?? Most Rainfall in US File Most Rainfall in US - Kauai Rainfall Average Enter Rainfall 8.6 9.2 10.5 14.2 10.0 6.4 3.2 2.9 5.9 8.8 9.2 7.4 Average Rainfall per Month is 8.0 inches FIGURE 6-116 tohoto EBS
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
