Write a program in C++ that determines a student’s grade.

Write a program that determines a student’s grade. 


Write a program that determines a student’s grade. The program will read three types of scores (quiz, mid-term, and final scores) and determine the grade based on the following rules:

-if the average score =90% =>grade=A 
-if the average score >= 70% and <90% => grade=B 
-if the average score>=50% and <70% =>grade=C 
-if the average score<50% =>grade=F



#include<iostream>
using namespace std;
int main()
{
 float q,m,f,av;
 cout<<"Enter your Quiz scores: ";
 cin>>q;
 cout<<"Enter your Mid-term scores: ";
 cin>>m;
 cout<<"Enter your Final scores: ";
 cin>>f;
 av=(q+m+f)/3;

 if (av>=90)
{
 cout<<"Your Grade is 'A' ";
 }else if(av>70 && av<90)
 {
 cout<<"Your Grade is 'B'";
 }else if(av>50 && av<70)
 {
 cout<<"Your Grade is 'C' ";
 }else if(av<50)
 {
 cout<<"Your Grade is 'F' ";
}
}

Write a program in C++ that determines a student’s grade.