Answer to Question #95818 in Python for Tobe

Question #95818
Test if a number grade is an A (greater than or equal to 90). If so print "Great!".
1
Expert's answer
2019-10-07T08:38:06-0400
#First example
def grade(number):
    return "Great" if number >= 90 else "Not Great"
print(grade(int(input())))

#second example
number = int(input())
if number >= 90:
  print("Great")
else:
  print("Not great")

#Third example
print( "Great" if int(input()) >= 90 else "Not Great")

You can use any of the above methods


Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS