Posts Tagged hashset

C++ For C# Developers: Part 46 – Other Containers Library

Tags: , , ,

Array-like containers aren’t the only containers we need. Today we’ll look at the non-array containers the C++ Standard Library provides, including its equivalents of Dictionary, HashSet, and LinkedList.

Read the rest of this article »

No Comments

Which Hash Set is Fastest?

Tags: , , ,

Say you need to keep track of things you’ve already done, perhaps to avoid doing them again. What’s the fastest way to do that? HashSet<T> seems like a natural fit, so you might choose that without a second thought. But is it faster than similar collections like Hashtable and Dictionary<TKey, TValue>? Today’s article puts all three to the test to see which one can insert elements, check for containment, and remove elements the quickest. Read on for the surprising results!

Read the rest of this article »

2 Comments