Question
Project Performers A particular talent competition has five judges, each of whom awards a score between 0 and 10 to each performer. Fractional scores, such
Project Performers A particular talent competition has five judges, each of whom awards a score between 0 and 10 to each performer. Fractional scores, such as 8.3, are allowed. A performers final score is determined by dropping the highest and the lowest score received then averaging the three remaining scores. Write a program that calculates the score of each performer and determines the winner. Assume theres only one winner! Input: Read data from an input file named performers.txt. First create the input file: copy and paste the following data into a new text file: performers.txt John 7.0 7.8 7.1 7.9 7.5 Dan 8.3 2.9 9.8 9.2 9.7 Mary 8.3 8.0 8.9 7.9 8.5 Andrew 9.1 8.9 9.0 8.7 9.1 Sue 9.0 8.8 9.1 9.7 9.3 Linda 8.2 8.4 8.9 9.3 8.5 David 9.0 5.6 8.9 9.9 7.3 Ann 7.9 8.2 7.6 8.1 8.0 You may assume that a performer is identified by its unique first name (no two performers have the same first name). Output: Write the number of participants, the name of the winner and the winners score to the screen. Write to a file named results.txt the names of the performers and their final score. // NOTE: You must write documentation for each function see next page Design: Your program should include 7 functions in addition to main(), as shown below: printInfo to display a welcome message and some information about the program open the input file open the output file for each customer in the file repeat the following: getScores to read a performers name and scores // see getRectangle in 6B calculateScore to calculate a performers score; // see calculateRectangle this function calls two functions: findLowest to find the lowest score findHighest to find the highest score writeScore to write to the output file a performers score // see writeRectangle close the input file close the output file printEnd to display an end-of-the-program message NOTE: You must write documentation for each function. Choose a style or create your own style and be consistent. A one-line comment is not an acceptable style. //********************************************************* // This function accepts the number of hours worked as an // argument and returns the employees pay for // non-overtime hours. //********************************************************* /********************************************************** This function accepts the number of hours worked as an argument and returns the employees pay for non-overtime hours. */ /**~*~* This function accepts the number of hours worked as an argument and returns the employees pay for non-overtime hours. *~**/
Please use IDE code blcok
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started