0

[SOLVED] Dictionary<,> == HashTable?

or its different but similar?

13th Jun 2021, 10:03 PM
Kiwwi#
Kiwwi# - avatar
2 Respuestas
+ 1
I didn't even realize HashTable was still being included after all these years since generics were supported in .NET 2, back in 2006. I just now saw that it's carried forward into .NET 5 and 6-Preview as well. HashTable was pretty much replaced by Dictionary<TKey, TValue> once generics were released. At the very least, it's not recommended for new development. I assume it's still around only for really old legacy code. https://docs.microsoft.com/en-us/dotnet/api/system.collections.hashtable?view=net-5.0#remarks https://github.com/dotnet/platform-compat/blob/master/docs/DE0006.md That said, if you still want a list of differences, this link might help: https://www.c-sharpcorner.com/blogs/difference-between-dictionary-and-hashtable-in-c-sharp
29th Jun 2021, 6:08 AM
David Carroll
David Carroll - avatar
+ 2
It is not implemented as a hash table but uses the same concept.
14th Jun 2021, 6:25 PM
Kail Galestorm
Kail Galestorm - avatar