py4e icon indicating copy to clipboard operation
py4e copied to clipboard

Lines 9, 11, 13 and 15 in py4e/code3/grade.py and py4e/code/grade.py

Open solomon-s-b opened this issue 5 years ago • 0 comments

It will print a 'B' if we put 0.9, a 'C' if we put 0.8, a 'D' if we put 0.7 and an 'F' if we put 0.6. Therefore, Exercise 3 in chapter 3 should be, as outlined in the book:

elif score >= 0.9:
    print 'A'
elif score >= 0.8:
    print 'B'
elif score >= 0.7:
    print 'C'
elif score >= 0.6:
    print 'D'

instead of:

elif score > 0.9:
    print 'A'
elif score > 0.8:
    print 'B'
elif score > 0.7:
    print 'C'
elif score > 0.6:
    print 'D'

solomon-s-b avatar Aug 13 '20 16:08 solomon-s-b