def main():
s = int(raw_input('Enter a number:'))
if s>=90:
grade = 'A'
elif s>=60:
grade = 'B'
else:
grade = 'C'
print grade,
if __name__ == '__main__':
main()
def main():
s = int(raw_input('Enter a number:'))
if s>=90:
grade = 'A'
elif s>=60:
grade = 'B'
else:
grade = 'C'
print grade,
if __name__ == '__main__':
main()
本文标题:题目:利用条件运算符的嵌套来完成此题:学习成绩>=90分的同学用
本文链接:https://www.haomeiwen.com/subject/woqvdftx.html
网友评论