Sollicitatievraag bij Logicalis

diff bet hashtable and dictionary

Antwoorden op sollicitatievragen

Anoniem

17 dec 2009

no box -unbox in dictionary

Anoniem

10 sep 2012

The generic dictionary is implemented as a hashtable, too. It is obviously generic and type-safe, hashtable is non-generic. Other non-generic dictionaries always have subtle differences: SortedList is sorted automatically; StringDictionary stores trings; ListDictionary is optimised for collections <10 elements; HybridDictionary behaves like a ListDictionary when small, and like a Hashtable when bigger; NameValueCollection can also be accessed by index.