Develop a C++ program to provide information regarding a recent downhill ski competition. Enter the names and times of the skiers and determine fasted speed, average speed, look up a skiers time, and display the skiers names and times.
Name | Time |
Leela | 2.03 |
Sarah | 2.40 |
Anna | 1.85 |
Keesha | 1.90 |
Heidi | 2.50 |
Requirements:
- Use parallel arrays to store the skier names and times. Declare a global const SIZE = 5 to represent the size of the array. Declare the arrays inside the main program. Do NOT use global variables. The arrays must be passed to the functions as parameters.
- Variable names must be descriptive and initialized.
- Create a menu to ask the user if they want to
- Determine the fastest skier
- Calculate the average time
- Find the time of a skier
- Display the skiers and their times
- Display the menu in the main program and then have functions for each of the menu items.
- The four functions will be
- Display fastest skier
- Display average time
- Display skiers time. In this function, flag if the user enters a name that is not in the list. Display a message to let the user know the name was not in the list.
- Display the skiers and their times
- Output must be labelled and easy to read as shown in the sample output below.
- Program must be documented with the following:
- // Name
- // Date
- // Program Name
- // Description
Reviews
There are no reviews yet.