I manage relatively small transient dictionaries in my program. My question: is it significantly more efficient to reuse them (with mymap.clear() after use), rather than to delete the old ones and create new ones?
Also, these dictionaries are currently implemented as std::unordered_map<std::string, int>. This works, but if (in light of the above usage pattern) another container (stl or not) is preferrable, I won't hesitate to switch this implementation.