This is a program to get a student mark, as an input from user and print its grade based on the following criteria:
if mark>=80 print 'A'
if mark between 70-80 print 'B'
if mark between 60-70 print 'C'
if mark between 50-60 print 'D'
if mark < 50 print 'F'

How do I fix this code when e.g someone gets 75 it says you got a B C D ?

percent = 85

if percent > 80:
print("You got an A!")
if percent > 70:
print("You got a B!")
if (percent >60):
print("You got a C!")
if (percent > 50):
print("You got a D!")
Else:
print("You got an F!")

For everything other than the first if use elif.

For future posts, please use the code tool, </>, to insert code blocks.