Is it possible to add items to sorted list with the same value, because when I am trying to do so it shows me an error:
“An entry with the same key already exists.”
If it’s possible, then how?
Is it possible to add items to sorted list with the same value, because
Share
It is not possible* to add duplicate keys as stated by other users.
In c# you might be able to use the Lookup class instead, which allows multiple values to be stored with the same key.
See: http://msdn.microsoft.com/en-us/library/bb460184.aspx
* It is possible, see comments, but only by defining a comparitor that never returns equality for equal items, which IMO is a really really bad idea.