Aimaz / Python sorting
public python v1 · immutable# this code sorts a list of words by their length# largest to smallest# This requires Python 2.4 or above for new __builtin__.sorted w/reverse kw arg optionwords = ["I", "am", "an", "owl"]sorted(((len(w), w) for w in words), reverse=True)