0

Im trying to sort these data in : - in alphabetical order with each person's highest score for the tests - by the highest score

ImYu
  • 13
  • 6

1 Answers1

1

Already asked an answered. See Sort a list by multiple attributes?

Also Both list.sort() and sorted() accept a reverse parameter with a boolean value.

One answer from the link

import operator
s = sorted(file, key = operator.itemgetter(1, 2),reverse=True)
Community
  • 1
  • 1
Robert Jacobs
  • 3,266
  • 1
  • 20
  • 30