Friday

December 19, 2014

December 19, 2014

Posted by **noh** on Sunday, April 14, 2013 at 2:32pm.

Consider this example problem: You are given 7 quiz scores of a student. You are to compute the final quiz score, which is the sum of all scores after subtracting the lowest one.

For example, if the scores are

8 7 8.5 9.5 7 5 10

then the final score is 50.

- Java programming -
**Alexis**, Sunday, April 14, 2013 at 2:39pmdouble[] score = {8, 7, 8.5, 9.5, 7, 5, 10};

Double min = 10; //the highest possible score is 10

Double total = 0;

for(int i = 0; i < score.length; i++)

{

total += score[i];

if(score[i] < min)

{

min = score[i];

}

}

total -= min;

System.out.println("Total = " + total);

- Java programming -
**Alexis**, Sunday, April 14, 2013 at 2:41pmOh, all the doubles have to be lower case.

- Java programming -
**noh**, Sunday, April 14, 2013 at 2:45pmthank you..:)

**Answer this Question**

**Related Questions**

algebra - Use the five steps for problem solving to answer the following ...

programming - Write a program which allows user to enter 10 student names and ...

algebra - please translate “A student scored five points more on the second quiz...

math - Tim wants his mean (average) quiz score in history class to be 90. His ...

Math - An instructor gives regular 20-point quizzes and 100-point exams in a ...

Java Programming - How to create a two dimensional arrays that stored the score ...

Math - I have this question for summer homework: "Mary's quiz scores were 92, 85...

Math - You have a mean score of 86 on 9 quizzes. The teacher decides to drop ...

statistics - For this class, the first quiz had a mean of 90.4% with a standard ...

Math - John has scores of 88,73,90,85,93 on five math quizzes. What scores must ...