subject

You are working for a company that is responsible for determining the winner of a prestigious international event, Men’s Synchronized Swimming. Scoring is done by eleven (11) international judges. They each submit a score in the range from 0 to 100. The highest and lowest scores are not counted. The remaining nine (9) scores are averaged and the median value is also determined. The participating team with the highest average score wins. In case of a tie, the highest median score, among the teams that are tied for first place, determines the winner. Scoring data is be provided in the form of a text file. The scoring data for each team consists of two lines; the first line contains the team name; the second line contains the eleven (11) scores. You will not know ahead of time how many teams will participant. Your program will:
Prompt the user for the name and location of the scoring data file.
Process the sets of records in the file.
Read and store the team name in a string variable.
Read and store the scores in an array.
Display the team name followed by the complete set of scores on the next line.
Calculate and display to two decimal places the average of the nine qualifying scores, dropping the lowest and highest scores.
Determine and display the median value among the qualifying scores.
Display the count of the number of participating teams.
Display the winning team name and their average score. Indicate if they won by breaking a tie with a higher median score value.
A sample data file has been provided to allow you to test your program before submitting your work. Records in the sample data file look like this:
Sea Turtles
11 34 76 58 32 98 43.5 87 43 23 22
Tiger Sharks
85 55 10 99 35 5 65 75 8 95 22
The Angry Piranhas
30 10 80 0 100 40 60 50 20 90 70
The average score for the Sea Turtles was 46.5. The Angry Piranhas and the Tiger Sharks both had an average score of 50.0. The tiger sharks had a median value of 55.0, making them the winners of the competition.
You will define and use at least one function in your solution. As a suggestion, you should consider calling a function that sorts the array of judge’s score values into ascending order (lowest to highest). The advantage of doing this is that after being sorted, the lowest value is the first entry in your array and the highest value is the last entry in your array.
The average or arithmetic mean is a measure of central tendency. It is a single value that is intended to represent the collection of values. For this problem, you will only use nine of the values to determine the average. You will not include the highest score and the lowest score.
The median is another measure of central tendency. The median is often referred to as the middle value. In a set of values, half the values are less than the median and the other half are greater than the median. In a sorted array of five elements, the median is the third element. There are two values that are less then it and there are two values that are greater than it. In a sorted array of six values, the median is the simple average of the third and fourth values. In some cases, the median is a better representative value than the average.
You are encouraged to read the article entitled "Mixing getline with cin".
To receive full credit for this programming assignment, you must:
Use the correct file name.
Submit a program that executes correctly.
Interact effectively with the user.
Grading Guideline:
Correctly name the file submitted.
Create a comment containing the student’s full name.
Document the program with other meaningful comments.
Prompt the user for a file name and location.
Open, read, and process all the data in the input file.
Store the judge’s scores in an array.
Correctly display the team name and all scores.
Calculate and display the average score correctly.
Calculate and display the median score correctly.
Correctly count and display the number of competing teams.
Correctly determine and display the winning team and score.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 11:40
Design a pos circuit that displays the letters a through j on a seven-segment indicator. the circuit has four inputs w, x, y, and z which represent the last 4 bits of the uppercase ascii code for the letter to be displayed. thus, if wxyz = 0001 then "a" will be displayed. (any answer with 22 or fewer gates and inverters, not counting any for the inputs, is acceptable)
Answers: 2
question
Computers and Technology, 23.06.2019 20:00
How much current flows through the alternator brushes? a. 2–5 a b. 25–35 a, depending on the vehicle c. 5–10 a d. 10–15 a
Answers: 2
question
Computers and Technology, 23.06.2019 21:30
Examine the list below. which factors positively affect lifetime income? check all that apply.
Answers: 1
question
Computers and Technology, 24.06.2019 11:20
William travels a lot on business purpose. he needs to regularly communicate with his business partner. he also needs to send out weekly reports to his boss while he is traveling. which web-based application best suits william’s needs? (social media, webmail, wiki) is the best web-based application for william. he can access this application via the internet using a (digital cable, fax machine, web browser).
Answers: 1
You know the right answer?
You are working for a company that is responsible for determining the winner of a prestigious intern...
Questions
question
Mathematics, 17.10.2021 14:00
question
English, 17.10.2021 14:00
question
English, 17.10.2021 14:00
question
Mathematics, 17.10.2021 14:00
Questions on the website: 13722367