b964: 第 1 題 成績指標
http://zerojudge.tw/ShowProblem?problemid=b964
- while True:
- try:
- input()
- x = [int(x) for x in input().split()]
- x = sorted(x)
- y = ""
- for i in range(len(x)):
- y += str(x[i])+" "
- print(y[:-1])
-
- if x[0] >= 60:
- print("best case")
- else:
- for i in range(len(x)):
- if x[-i-1] < 60:
- print(x[-1-i])
- break
-
- if x[-1] < 60:
- print("worst case")
- else:
- for i in range(len(x)):
- if x[i] >= 60:
- print(x[i])
- break
- except:
- break