Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Hello, this program requires I inpute a file (given by the professor), but I don't know how I can upload the file on chegg from

Hello, this program requires I inpute a file (given by the professor), but I don't know how I can upload the file on chegg from my computer. However, below is what the program is asking to do:

Write a C++ console program that outputs diving competition results in a table form and determines the top three medals of a particular diving contest. Input file will come from the final round of six dives, and divers will be listed in reverse order from the semifinals. The input will include the following information:

I

1. The name of the particular diving contest on the first line

2. The second line indicates the number of contestants m

3. for each of the next m lines:

(a). the last name of the diver (max 15 characters) followed by a space.

(b). The NOC (National Olympic Committee) of the diver (max 3 characters) followed by two spaces.

(c). The degrees of difficulty for each of the six dives (where the first number indicates the DD of the dive 1, etc) separated by one space followed by two spaces

(d). The judges seven scores separated with a space from each set of six dives (where the first seven numbers indicate the scores from dive 1, the next seven from dive 2, etc). each set of scores are separated by two spaces.

II

Output the scoreboard and rank the divers in particular event. For each event output:

1. Output the name of the event and heading FINAL STANDINGS

2. Print the headers and the diver's results, where:

(a). RANK -diver order is based on the total calculated points. If the total calculated points for particular dives are the same, it is considered a tie for the particular place. For example, if there was a tie for the second place the ranking would go: 1 2 2 4 (no third place).

(b). NOC -(National Olympic Committee) or country

(c). DD- Degree of Difficulty

(d). The seven Judges scores (J1, J2, J3, J4, J5, J6, J7) for all six dives, where a/before the score denotes a dropped score

(e) TOT PTS - (Total Points) The total even points of the particular diver after all six dives.

(f). PTS BHND - (points Behind) The number of points behind (difference) between the first diver and each of the divers in the event. III Finally, output the top three divers with MEDALISTS head on one line, with the GOLD, SILVER and BRONZE titles with the NAME and NOC on each separate lines.

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

Step: 3

blur-text-image

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

Contemporary Issues In Database Design And Information Systems Development

Authors: Keng Siau

1st Edition

1599042894, 978-1599042893

More Books

Students also viewed these Databases questions

Question

What is a module and why are modules important?

Answered: 1 week ago

Question

Describe the five elements of the listening process.

Answered: 1 week ago