Advertisement
makispaiktis

Panellinies System

Aug 27th, 2021 (edited)
903
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.18 KB | None | 0 0
  1. print("***************** RULE 1 *****************")
  2. maxGrade1 = int(input("Max grade 1: "))
  3. maxGrade2 = int(input("Max grade 2: "))
  4. maxGrade3 = int(input("Max grade 3: "))
  5. maxGrade4 = int(input("Max grade 4: "))
  6. while maxGrade1 + maxGrade2 + maxGrade3 + maxGrade4 != 20000:
  7.     maxGrade1 = int(input("Max grade 1: "))
  8.     maxGrade2 = int(input("Max grade 2: "))
  9.     maxGrade3 = int(input("Max grade 3: "))
  10.     maxGrade4 = int(input("Max grade 4: "))
  11. print()
  12. print("*****************  PLAFON ******************")
  13. plafon = int(input("Plafon = "))
  14. print()
  15. print("******** STUDENT GRADES (MAX = 100) ********")
  16. grade1 = float(input("Grade 1: "))
  17. grade2 = float(input("Grade 2: "))
  18. grade3 = float(input("Grade 3: "))
  19. grade4 = float(input("Grade 4: "))
  20. grade = grade1 * maxGrade1 + grade2 * maxGrade2 + grade3 * maxGrade3 + grade4 * maxGrade4
  21. grade /= 100
  22. grade = int(grade)
  23. print()
  24. if grade > plafon:
  25.     print("Grade = " + str(grade) + " > " + str(plafon))
  26.     print("You passed!")
  27. elif grade < plafon:
  28.     print("Grade = " + str(grade) + " < " + str(plafon))
  29.     print("You did not pass...")
  30. else:
  31.     print("Grade = " + str(grade) + " = " + str(plafon))
  32.     print("You passed!")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement