I thought I had solved my problem when I discovered SortedSet but this is not supported (or disabled on purpose?) by the judging server. Does anyone know of a suitable alternative?
One alternative I've found myself is SortedList but I'm getting an error I don't understand. For instance, when I have
- Code: Select all
SortedList<Node, int> queue = new SortedList<Node, int>()
calling queue.Min() results in an error that at least one object must implement IComparable. However, Node implements IComparable and has the public member int CompareTo(object other).
Does anyone know what I'm doing wrong here?