(Solved) : Question Asks Write Program Calculates Gpa Final Version Looking Like Wrong Char Grade Int Q40952837 . . .

The question asks to write a program that calculates GPA withthe final version looking like- What am I doing wrong?

My name is: Ima Goodstudent Enter a grade to continue or any other value to quit: Enter the number of credit hours: Enter a g

char grade;
int TotalPoints,TotalCredit,count=0;
printf(“My name is: Joel Duben”); // Prints name
do
{
printf(“Enter a grade to continue or any other value to quit:”);
scanf(“%c”,&grade);
if (grade==’A’ || grade==’B’ || grade==’C’ || grade==’D’ ||grade==’a’ || grade==’b’ || grade==’c’ || grade==’d’)
{
printf(“Enter the number of credit hours: “);
scanf(“%d”,&TotalCredit);
TotalPoints+=TotalCredit;
count++;
scanf(“%c”,&grade);
}
else
break;
}
while (1);
{
printf(“The total number of credit hours is: %d and GPA is%fn”,TotalPoints,(float) TotalCredit);
}
getch();
return 0;

My name is: Ima Goodstudent Enter a grade to continue or any other value to quit: Enter the number of credit hours: Enter a grade to continue or any other value to quit: Enter the number of credit hours: Enter a grade to cont inue or any other value to quit: Enter the number of credit hours: 2 Enter a grade to cont inue or any other value to quit: 9 and the GPA is: 3.000 The total number of credit hours is: Show transcribed image text My name is: Ima Goodstudent Enter a grade to continue or any other value to quit: Enter the number of credit hours: Enter a grade to continue or any other value to quit: Enter the number of credit hours: Enter a grade to cont inue or any other value to quit: Enter the number of credit hours: 2 Enter a grade to cont inue or any other value to quit: 9 and the GPA is: 3.000 The total number of credit hours is:

Expert Answer


Answer to The question asks to write a program that calculates GPA with the final version looking like- What am I doing wrong? cha…

Leave a Comment

About

We are the best freelance writing portal. Looking for online writing, editing or proofreading jobs? We have plenty of writing assignments to handle.

Quick Links

Browse Solutions

Place Order

About Us

× How can I help you?