Pergunta de entrevista da empresa Logicalis

diff bet hashtable and dictionary

Respostas da entrevista

Sigiloso

17 de dez. de 2009

no box -unbox in dictionary

Sigiloso

10 de set. de 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.