Problem: Another college-level class is graded based ONLY on exam performance. T
ID: 3638048 • Letter: P
Question
Problem: Another college-level class is graded based ONLY on exam performance. There are a total of four exams in this course with the first three being worth 100 points each and a fourth exam worth 150 points. The scale for this class is 85% required to earn an A, 75% for B, 65% for C, 55% for D.( not allow to use 'if' as code)
Exam Score Grade
----------------
1 55 D
2 70 C
3 65 C
4 100 C
----------------
Total: 290
Grade: D
Explanation / Answer
#include void main(void){ int total; int test1; int test2; int test3; int test4; float tempTest4; char grade1; char grade2; char grade3; char grade4; char final; printf("Please enter the score of test 1: "); scanf("%d",&test1); printf("Please enter the score of test 2: "); scanf("%d",&test2); printf("Please enter the score of test 3: "); scanf("%d",&test3); printf("Please enter the score of test 4: "); scanf("%d",&test4); tempTest4=test4; tempTest4=(tempTest4/150)*100; ////////////////////////////// if(test1>=85){ grade1='A'; } else if(test1>=75 && test1=65 && test1=55 && test1=85){ grade2='A'; } else if(test2>=75 && test2=65 && test2=55 && test2=85){ grade3='A'; } else if(test3>=75 && test3=65 && test3=55 && test3=85){ grade4='A'; } else if(tempTest4>=75 && tempTest4=65 && tempTest4=55 && tempTest4=85){ final='A'; } else if(total>=75 && total=65 && total=55 && totalRelated Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.