Given a list (say, of numbers) L
, the method L.sort()
will put its elements in order. The function sorted(L)
returns a new list with the elements of L
in order. I would like a version of sorted
that will not return the elements of L
in sorted order, but rather, the permutation that puts them in sorted order. Does this exist in Sage? Thanks.