You are on page 1of 5

subject_1=input("Enter the marks of the first subject = ")

subject_2=input("Enter the marks of the second subject = ")


subject_3=input("Enter the marks of the thrid subject = ")
subject_4=input("Enter the marks of the fourth subject = ")
subject_5=input("Enter the marks of the fifth subject = ")
subject_6=input("Enter the marks of the sixth subject = ")
subject_7=input("Enter the marks of the seventh subject = ")
subject_8=input("Enter the marks of the eight subject = ")
subject_9=input("Enter the marks of the ninth subject = ")
subject_10=input("Enter the marks of the tenth subject = ")
subject_11=input("Enter the marks of the eleven subject = ")

   
if subject_1=='A':
        sub=4
elif subject_1=='A-':
        sub=3.8
elif subject_1=='B+':
        sub=3.5
elif subject_1=='B':
        sub=3
elif subject_1=='B-':
        sub=2.8
elif subject_1=='C+':
        sub=2.5
   

if subject_2=='A':
    sub2=4
   
elif subject_2=='A-':
    sub2=3.8
elif subject_2=='B+':
    sub2=3.5
elif subject_2=='B':
    sub2=3
elif subject_2=='B-':
    sub2=2.8
elif subject_2=='C+':
    sub2=2.5
   

 
if subject_3=='A':
    sub3=4
elif subject_3=='A-':
    sub3=3.8
elif subject_3=='B+':
    sub3=3.5
elif subject_3=='B':
    sub3=3
elif subject_3=='B-':
    sub3=2.8
elif subject_3=='C+':
    sub3=2.5
   

if subject_4=='A':
    sub4=4
elif subject_4=='A-':
    sub4=3.8
elif subject_4=='B+':
    sub4=3.5
elif subject_4=='B':
    sub4=3
elif subject_4=='B-':
    sub4=2.8
elif subject_4=='c+':
    sub4=2.5
   
if subject_5=='A':
        sub5=4
elif subject_5=='A-':
        sub5=3.8
elif subject_5=='B+':
        sub5=3.5
elif subject_5=='B':
        sub5=3
elif subject_5=='B-':
        sub5=2.8
elif subject_5=='C+':
        sub5=2.5
   
if subject_6=='A':
        sub6=4
elif subject_6=='A-':
        sub6=3.8
elif subject_6=='B+':
        sub6=3.5
elif subject_6=='B':
        sub6=3
elif subject_6=='B-':
        sub6=2.8
elif subject_6=='C+':
        sub6=2.5
   
if subject_7=='A':
        sub7=4
elif subject_7=='A-':
        sub7=3.8
elif subject_7=='B+':
        sub7=3.5
elif subject_7=='B':
        sub7=3
elif subject_7=='B-':
        sub7=2.8
elif subject_7=='C+':
        sub7=2.5
   
if subject_8=='A':
        sub8=4
elif subject_8=='A-':
        sub8=3.8
elif subject_8=='B+':
        sub8=3.5
elif subject_8=='B':
        sub8=3
elif subject_8=='B-':
        sub8=2.8
elif subject_8=='C+':
        sub=2.5

if subject_8=='A':
        sub8=4
elif subject_8=='A-':
        sub8=3.8
elif subject_8=='B+':
        sub8=3.5
elif subject_8=='B':
        sub8=3
elif subject_8=='B-':
        sub8=2.8
elif subject_8=='C+':
        sub=2.5
   
if subject_9=='A':
        sub9=4
elif subject_9=='A-':
        sub9=3.8
elif subject_9=='B+':
        sub9=3.5
elif subject_9=='B':
        sub9=3
elif subject_9=='B-':
        sub9=2.8
elif subject_9=='C+':
        sub9=2.5

if subject_10=='A':
        sub10=4
elif subject_10=='A-':
        sub10=3.8
elif subject_10=='B+':
        sub10=3.5
elif subject_10=='B':
        sub10=3
elif subject_10=='B-':
        sub10=2.8
elif subject_10=='C+':
        sub10=2.5

if subject_11=='A':
        sub11=4
elif subject_11=='A-':
        sub11=3.8
elif subject_11=='B+':
        sub11=3.5
elif subject_11=='B':
        sub11=3
elif subject_11=='B-':
        sub11=2.8
elif subject_11=='C+':
        sub11=2.5  
print('\n\n\n')
credit=int(input('Enter the credit hour for first subject = '))
credit2=int(input('Enter the credit hour for second subject = '))
credit3=int(input('Enter the credit hour for third subject = '))
credit4=int(input('Enter the credit hour for fourth subject = '))
credit5=int(input('Enter the credit hour for fifth subject = '))
credit6=int(input('Enter the credit hour for sixth subject = '))
credit7=int(input('Enter the credit hour for seventh subject = '))
credit8=int(input('Enter the credit hour for eight subject = '))
credit9=int(input('Enter the credit hour for ninth subject = '))
credit10=int(input('Enter the credit hour for tenth subject = '))
credit11=int(input('Enter the credit hour for eleventh subject = '))

sum_of_credit_hour=credit+credit2+credit3+credit4+credit5+credit6+credit7+credit8+credit9+cre
dit10+credit11

result=credit*sub
result2=credit2*sub2
result3=credit3*sub3
result4=credit4*sub4
result5=credit5*sub5
result6=credit6*sub6
result7=credit7*sub7
result8=credit8*sub8
result9=credit9*sub9
result10=credit10*sub10
result11=credit11*sub11

total=result+result2+result3+result4+result5+result6+result7+result8+result9+result10+result1
1

display=total/sum_of_credit_hour

print('the marks for first subject is = ', sub)


print('the marks for second subject is = ', sub2)
print('the marks for third subject is = ', sub3)
print('the marks for fourth subject is = ', sub4)
print('the marks for fifth subject is = ', sub5)
print('the marks for sixth subject is = ', sub6)
print('the marks for seventh subject is = ', sub7)
print('the marks for eight subject is = ', sub8)
print('the marks for ninth subject is = ', sub9)
print('the marks for tenth subject is = ', sub10)
print('the marks for eleventh subject is = ', sub11)

print(display)

You might also like