python if elif else 使用
当前位置:以往代写 > Python教程 >python if elif else 使用
2019-06-14

python if elif else 使用

python if elif else 使用
python">1 #!/usr/bin/env python
  2 while True:
  3 
  4     score=int(raw_input('please input your score(0-100): '))
  5     if score >=90 and score <=100:
  6         print 'your are A type'
  7     elif 80<=score<=89:
  8         print 'you are B type'
  9     elif 70<=score<=79:
 10         print 'you are C type'
 11     elif 60<=score<=69:
 12         print 'you are D type'
 13     elif 0<=score<60:
 14         print 'you are F type'
 15     else:
 16         print 'you are input a wrong score.'

标签:python

    关键字:

在线提交作业