Skip to content

What's the difference between SortedDictionary and OrderedDictionary?

Frank

Asked Mar 20, 2007, 10:46 PM EDT1 answer
Share
LinkedInX
Both of them are dictionaries and sorted/ordered, then what is the difference?

1 Answer

Know the answer? Post it. Somebody with the same question will find it here.

  • +1
    Hi,

    SortedDictionary and Ordereddictionary both contains key/value pairs. But these key/value pairs are sorted by keys in SortedDictionary but not in Ordereddictionary. Also, Ordereddictionary values can be accessed by using both key or index rather than only key in SortedDictionary or a normal dictionary like hashtable.
    +1