STL中的CMapWordToPtr? [英] CMapWordToPtr in STL?
本文介绍了STL中的CMapWordToPtr?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
现代STL中CMapWordToPtr的等价是什么?是unordered_map还是只是map或somethig else更好?
What would be an equvalent of CMapWordToPtr in modern STL? Is it unordered_map or just map or somethig else is better?
推荐答案
我认为std :: unordered_map
适合优于std :: map
,因为前者是通过哈希函数实现的,后者是使用二叉搜索树实现的。
I think thestd::unordered_map
fits better thanstd::map
, because the former is implemented via a hash function while the latter with binary search trees.
这篇关于STL中的CMapWordToPtr?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文