In .NET, the Generics Lists have a sort function that accepts IComparer
or Comparison
. I'd like to sort just part of a list. Hopefully I can specify the start index, count of elements to sort, and a lambda function. It looks like you can only use lambda functions to do this if you're sorting the entire list. Is that right or did I miss something?
Additional Requirements:
- Sort in place (to save memory/time)
- Final list has the same length as the original list