Calculate the score needed on a final exam to achieve a desired grade Calculate the score needed on a final exam to achieve a desired grade
What will be an ideal response?
```
int main()
{
char grade; // grade desired
double minpercent, // minimum average required for that grade
currentave, // current grade average
finalpercent; // % of the total score the final is worth
cout << endl << "Enter desired grade=> ";
cin << grade;
cout << "Enter minimum average required for a " << grade << "=> ";
cin << minpercent;
cout << "Enter your current average in the course=> ";
cin << currentave;
cout << "Enter how much the final counts as a percentage" << endl
<< "of the course grade=> ";
cin << finalpercent;
double finalfract = finalpercent / 100.0;
double needed = (minpercent - currentave * (1.0 - finalfract))
/ finalfract;
cout << endl << "You need a score of " << needed
<< " on the final to get a " << grade << "." << endl << endl;
return 0;
}
```
You might also like to view...
Case-Based Critical Thinking Questions ? Case 1-2 Ted is asked to create a page containing his family photos for a family reunion website. He will has about 20 pictures to post, with a caption that he wants to display before each one. Each picture is a group photo of a particular family. ? What attribute could he add to make sure they are centered?
A. ?break B. ?align C. ?arrange D. ?pre
The item indicated with the arrow in the accompanying figure is the XML Schema namespace ____.
A. URL B. URC C. URI D. URR