Write a program for a professor to calculate the average grade of a student. The program should accept as many grades as the professor wants to enter. Therefore, ask the professor for the first grade, the second grade, and so on until the professor enters a negative value. A negative value indicates that the professor is finished entering grades. Once the professor is finished, your program should output: a) the average grade of the student b) the letter grade of the student
without for statement
C code
#include<stdio.h>
int main(){
double score,avg=0,sum=0;
int n=0;
char grade;
printf("Enter grade %d: ",n+1);
scanf("%lf",&score);
while(score>=0){
sum+=score;
n+=1;
printf("Enter grade %d:
",n+1);
scanf("%lf",&score);
}
avg=sum/n;
if(avg>90){
grade='A';
}
else if(avg>80){
grade='B';
}
else if(avg>70){
grade='C';
}
else if(avg>60){
grade='D';
}
else
grade='F';
printf("Average score: %.2f Letter Grade: %c
",avg,grade);
return 0;
}

Write a program for a professor to calculate the average grade of a student. The program...
You will create a Grade Program that will calculate students’ weighted averages. You are going to have the user enter lab grades, test grades, and project grades. You will then display a grade report of each individual average along with their overall average and letter grade. Ask the user to enter their lab grades. Call the averageGrade function that will allow the user to enter their grades and calculate their average. averageGrade Function: This will pass the average back to...
Write a program that asks the user for a student name and asks for grades until the user enters a non-number input, it should then ask if the user wants to enter another student, and keep doing the process until the user stops adding students. The student’s must be stored in a dictionary with their names as the keys and grades in a list. The program should then iterate over the dictionary elements producing the min, max, and mean of...
Write a C++ program that will provide a user with a grade range if they enter a letter grade. Your program should contain one function. Your function will accept one argument of type char and will not return anything (the return type will be void), but rather print statements to the console. Your main function will contain code to prompt the user to enter a letter grade. It will pass the letter grade entered by the user to your function....
Write a program that will calculate your letter grade at the end of the semester for CSIS130. Your program will read an input file that shall contain all the tests scores and lab scores for the semester, and the input file data should be in the following format: full name of student Test1 Score (0…100), Test2 Score (0..100) , Final Exam Score (0..100), Total Number of Labs: N NLab Scores (0=Fail, 1=Pass) [You will have N lab scores each separated...
Write a program that prompts the user for student grades, calculates and displays the average grade in the class. The user should enter a character to stop providing values.
IN C You will be creating a program to help a teacher calculate final grades for a class. The program will calculate a final letter grade base on a standard 90/80/70/60 scale. You will be taking input from a file that contains all of the names and grades of each student. You will find the average for each student and output each student's final letter grade. Your program should accept the filename from the command-line Add error checking to make...
using C# Write a program which calculates student grades for multiple assignments as well as the per-assignment average. The user should first input the total number of assignments. Then, the user should enter the name of a student as well as a grade for each assignment. After entering the student the user should be asked to enter "Y" if there are more students to enter or "N" if there is not ("N" by default). The user should be able to...
C ++ . In professor Maximillian’s course, each student takes four exams. A student’s letter grade is determined by first calculating her weighted average as follows: (score1 + score2 + score3 + score4 + max_score) weighted_average = ----------------------------------------------------------------------- 5 This counts her maximum score twice as much as each of the other scores. Her letter grade is then a A if weighted average is at least 90, a B if weighted average is at least 80...
You have been hired by the CS Department to write code to help synchronize a professor and his/her students during office hours. The professor, of course, wants to take a nap if no students are around to ask questions; if there are students who want to ask questions, they must synchronize with each other and with the professor so that only one person is speaking at any one each student question is answered by the professor, and time, no student...
-You are going to write a program to help me determine the final grade and calculate some summary stats. The steps are described below: 1. First, create a dictionary of 10 students with student name as key and score as value. •For simplicity, name students as student 1, student 2, etc. Scores are random integers from 0-100 2. Calculate the average score in the class 3. Determine the letter grade based on the following scheme :•A if score >=...