vl-sort-i


(vl-sort-i lst comparator)

This function returns the list of indices for the sorted elements from lst using the specified comparator function.

Arguments

lst  (list) any list of items
comparator  (symbol, function, lambda) function used for the boolean comparison; must return NIL resp. non-NIL

Return

(list) returns a list of integers, which represent the indices of the sorted elements

Example

(vl-sort-i '("c" "b" "d" "a" "a" "z") '<)
returns (4 3 1 0 2 5)

Remarks

duplicate elements are not removed (from the internally sorted lst list)  !



©  Bricsys NV. All rights reserved.