Is there some function which would return me the N highest elements from some list?
I.e. if max(l) returns the single highest element, sth. like m
max(l)
m
The function in the standard library that does this is heapq.nlargest