Returns the given objects in sorted order.
If the parameter by is specified, sorting is done according to it. In this case
the number of objects in by have to match that of objects.
The parameter desc determines if the order should be reversed.