It seems I cannot find the C # suite (C # 3.0 that I use Unity3D) I need:
- I need to be able to quickly add and remove elements on repeat , as in
LinkedList . - I need to sort it often several times, e.g.
Sort in a List (interested in any merge, quicksort and radixsort) - I need to sort according to different sorting functions , because I have to sort according to different fields like Name, Surname, etc. (therefore,
SortedList or SortedDictionary not appropriate).
The list seems to be “almost correct”, except that it is actually an array, and I cannot delete items randomly, iterating forward.
A LinkedList would be ideal, but the ability to sort by mistake (for a linked list it would be a natural merge, which, in addition, is stable, it might be required to be stable, not required at the moment).
It would be best to find that, in fact, the .NET sorting method already exists for LinkedList, and I don't know about that.
If I had time to implement such a class, I would go for a LinkedList with a sorting method using mergesort and a custom lambda as a comparison, however it seems that there is no material in .NET.
GameDeveloper Aug 19 '15 at 17:29 2015-08-19 17:29
source share