Files
  • main.py
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
maxScore = 1218000
scores = [874300, 879200, 1172100, 1141800, 933900, 1177200, 1190200, 1110100, 1158400, 985600, 1047200, 1049100, 1138600, 1170500, 1064500, 1190000, 1050200, 1090400, 1062800, 1061700, 1218000, 1068000, 1127700, 1144800, 1195100]

def scoreSettler(scoreList, maximum):
    orderedList = []
    while len(scoreList) > 0:
        for score in scoreList:
            if score > maximum:
                scoreList.remove(score)
            elif score == max(scoreList):
                orderedList.append(score)
                scoreList.remove(score)
    return orderedList
    
print scoreSettler(scores, maxScore)
Python 2.7.10 (default, Jul 14 2015, 19:46:27) [GCC 4.8.2] on linux