Skip to content

Instantly share code, notes, and snippets.

@axurright
Last active October 21, 2024 17:23
Show Gist options
  • Select an option

  • Save axurright/d7d2502947f156436148fb640cb7f97d to your computer and use it in GitHub Desktop.

Select an option

Save axurright/d7d2502947f156436148fb640cb7f97d to your computer and use it in GitHub Desktop.
A grade checker that ACTUALLY works in Python.
def gradeCheck():
grade = input("What grade did your get? (0-10): ")
if int(grade) == 0:
print("You failed the exam, better luck next time!")
elif int(grade) <= 5:
print("You still didn't pass but did decent.")
elif int(grade) < 10:
print("Nice job! You passed!")
if int(grade) == 10:
print("And you got a 10! Keep up that good job!")
gradeCheck()
# I got this to work well because I have way more experience with Python.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment