Write program to compute contestant-s score
Course:- Programming Languages
Reference No.:- EM1370743

Assignment Help
Expertsmind Rated 4.9 / 5 based on 47215 reviews.
Review Site
Assignment Help >> Programming Languages

A 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 performer's final score is determined by dropping the highest and lowest score received, then averaging the remaining scores. Write a program that uses this method to calculate a contestant's score. It should include the following functions:

•void getJudgeData( ) should ask the user for a judge's score, store it in a reference parameter variable, and validate it. This function should be called by main once for each of the five judges.
•void calcScore( ) should calculate and display the average of the three scores that remain after dropping the highest and lowest scores the performer received. This function should be called just once by main, and should be passed the five scores.
The last two functions, described below, should be called by calcScore, which uses the returned information to determine which of the scores to drop.

•float findLowest( ) should find and return the lowest of the five scores passed to it.
•float findHighest( ) should find and return the highest of the five scores passed to it.
Input validation: Do not accept judge scores lower than 0 or higher than 10.

Put your comment

Ask Question & Get Answers from Experts
Browse some more (Programming Languages) Materials
Write simple program which will prompt user for his or her gross salary. Your program than will display net salary whereby 11.00% of the gross salary is deducted for EPF
Develop 3 proposals for your development strategy, which include outsourcing (buy), insourcing (make), or a combination of both. You will present the pros and cons of each,
Create a program which calculate distance a boat travels across a river, given the width of the river, the boat's speed perpendicular to the river.
Modeling a Game Using Turing Machine, Select a game that can be modeled by a simple Turing machine. It should take a series of inputs (such as a set of moves by a player) and
Write a program in C# that simulates the operation of the turtle and implements a computerized sketchpad. Write several turtle graphics programs that draw interesting shapes
Create program which tests each member of Resistor class to ensure that they work properly. Complete the following Tasks: Create main function and instantiate three Resistor C
Create a very basic calculator, map out the numeric keypad (17 buttons) and an EditText view. If text is given, prompt the user with a message that complains about the error
Write the program which lets user enter a charge account number. The program must determine if number is valid by checking for it in following list.