Computer Science, asked by pranil777, 1 year ago

write a program in q basic to accept the marks of four subjects and calculate the average and display the grade .
the grades with respect to the average are given in the picture .

Attachments:

Answers

Answered by Swetha03K
7

m1=int(input("Enter mark 1:"))

m2=int(input("Enter mark 2:"))

m3=int(input("Enter mark 3:"))

m4=int(input("Enter mark 5:"))

t=m1+m2+m3+m4+m5

avg=t/5

if avg>=80:

       print("Distinction")

elif 60<=avg<80:

       print("First division")

elif 45<=avg<60:

       print("Second division")

elif 40<=avg<45:

       print("Pass")

elif avg<40:

       print("Not Promoted")

Similar questions