Question

In: Computer Science

A Class assessment is based on Three Examinations, Homework and a Final Project. The weight for...

A Class assessment is based on Three Examinations, Homework and a Final Project. The weight for each category is as follows: Ex 1, Ex 2 and Ex 3 Weight 45% of the overall grade, Homework Weight 25% and Final Project Weight 30%.

Write a C# program ( Console or GUI ) that prompts the user to enter the three examinations ( ex1, ex 2, and ex 3), homework and final project grades then calculate and display the overall grade along with a message, using the selection structure (if/else). The message is based on the following criteria:

  • “Excellent” if the overall grade is 90 or more.
  • “Good” if the overall grade is between 80 and 90 ( not including 90)
  • “Above Average” is the overall grade is between 70 and 80 ( not including 80)
  • “Average” if the overall grade is between 60 and 70 ( not including 70)
  • "Poor" if the overall grade is less than 60 ( not including 60)

Solutions

Expert Solution

Solution:

Code:

Output:

Copyable Code:

using System;

//Main class

class MainClass {

//Main method

public static void Main (string[] args)

{

//Declaration of variables

double ex1,ex2,ex3,homework,finalProject,totGrade=0;

//Prompt and get from users

Console.Write("Enter the Grade for Examination 1:");

ex1 = double.Parse(Console.ReadLine());

Console.Write("Enter the Grade for Examination 2:");

ex2 = double.Parse(Console.ReadLine());

Console.Write("Enter the Grade for Examination 3:");

ex3 = double.Parse(Console.ReadLine());

Console.Write("Enter the Grade Homework:");

homework = double.Parse(Console.ReadLine());

Console.Write("Enter the Grade Final Project:");

finalProject = double.Parse(Console.ReadLine());

//Calculation of grade

totGrade=(((ex1+ex2+ex3)*(0.45))+(homework*(0.25))+(finalProject*(0.30)));

//Conditions

if(totGrade>=90)

{

//Print statement

Console.Write("Excellent:Your Grade is {0}.",totGrade);

}

else if(totGrade>=80 && totGrade<90)

{

//Print statement

Console.Write("Good:Your Grade is {0}.",totGrade);

}

else if(totGrade>=70 && totGrade<80)

{

//Print statement

Console.Write("Above Average:Your Grade is {0}.",totGrade);

}

else if(totGrade>=60 && totGrade<70)

{

//Print statement

Console.Write("Average:Your Grade is {0}.",totGrade);

}

else

{

//Print statement

Console.Write("Poor:Your Grade is {0}.",totGrade);

}

}

}


Related Solutions

On stat your assessment is based on: Final Exam 47% Learn based on‐line assessment 34% Assignments...
On stat your assessment is based on: Final Exam 47% Learn based on‐line assessment 34% Assignments 19% Consider three random variables X, Y and Z which respectively represent the exam, on‐line assessment total and assignment scores (out of 100%) of a randomly chosen student. Assume that X, Y and Z areindependent (this is clearly not true, but the answers may be a reasonable approximation). Suppose that past experience suggests the following properties of these assessment items (each out of 100%):...
This is the final assessment for the Accounting module. It contains three parts (Parts 1, 2,...
This is the final assessment for the Accounting module. It contains three parts (Parts 1, 2, and 3). Please follow the instructions carefully. Requirements Part 1: 1. Prepare the journal entries for each set of transaction data below. 2. Post the transactions in the ledger. 3. Extract the unadjusted trial balance as of January 31 of this current year. Part 2: For this section, prepare the following adjusted journal entries. 1. Record depreciation of $1,000 for equipment. 2. Accrue unpaid...
You are in a class titled Introduction to Artistic Expression, and your final project must be...
You are in a class titled Introduction to Artistic Expression, and your final project must be completed in class. You know that you will be given three objects and two boards to work with to create two separate displays. You also know that you must arrange the objects on the boards so they balance on a tiny pedestal. Once completed, one display will be a single object resting on a board balanced on top of a pedestal; the other will...
A science teacher tells her class that their final project requires the students to measure a...
A science teacher tells her class that their final project requires the students to measure a specific variable and determine the velocity of a car with no more than 2.5% error. Jennifer and Johnny work hard and decide the velocity of the car is 34.87 m/s. The teacher informs them that the actual velocity is 34.15 m/s. Will Jennifer and Johnny pass their final project? SHOW ALL YOUR WORK TO GET ANSWER.
Assessment: Final Report / Essay - An assessment of the economic impact of COVID 19 on...
Assessment: Final Report / Essay - An assessment of the economic impact of COVID 19 on the Australian economy – an International Macroeconomic perspective Likely implications for net foreign wealth
Assessment: Final Report / Essay - An assessment of the economic impact of COVID 19 on...
Assessment: Final Report / Essay - An assessment of the economic impact of COVID 19 on the Australian economy – an International Macroeconomic perspective how might changes to the exchange rate flow through to the domestic economy. Australia
Risk Assessment Homework In this assignment, you will perform a qualitative risk assessment, using a template...
Risk Assessment Homework In this assignment, you will perform a qualitative risk assessment, using a template that has been provided below.    A listing of threats has been prepopulated for you. These threats have been categorized by type as shown below:                                                    Threat Origination Category Type Identifier Threats launched purposefully P Threats created by unintentional human or machine errors U Threats caused by environmental agents or disruptions E Purposeful threats are launched by threat actors for a variety of reasons...
Create a Project and a Class called “FinalGrade” Write a Java program to compute your final...
Create a Project and a Class called “FinalGrade” Write a Java program to compute your final grade for the course. Assume the following (you can hard-code these values in your program). Assignments are worth 30% Labs are worth 40% Mid-term is worth 15% Final is worth 15% Ask for the grades in each category. Store them in a double variable. Print out the final percentage grade.           For example, Final Grade Calculation Enter percentage grades in the following order. Assignments,...
HOMEWORK PROJECT #1 – SHOPPING CART Part I. Create two files to submit: ItemToPurchase.java – Class...
HOMEWORK PROJECT #1 – SHOPPING CART Part I. Create two files to submit: ItemToPurchase.java – Class Definition ShoppingCartPrinter.java – Contains main() method Build the ItemToPurchase class with the following specifications: Specifications Description ItemToPurchase(itemName) itemName – The name will be a String datatype and Initialized in default constructor to “none”. ItemToPurchase(itemPrice) itemPrice – The price will be integer datatype and Initialized in default constructor to 0. ItemToPurchase(itemQuantity) itemQuantity – The quantity will be integer datatype Initialized in default constructor to 0....
JAVA Homework 1) Create a die class. This is similar to the coin class , but...
JAVA Homework 1) Create a die class. This is similar to the coin class , but instead of face having value 0 or 1, it now has value 1,2,3,4,5, or 6. Also instead of having a method called flip, name it roll (you flip a coin but roll a die). You will NOT have a method called isHeads, but you will need a method (call it getFace ) which returns the face value of the die. Altogether you will have...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT